cancel
Showing results for 
Search instead for 
Did you mean: 

Java Proxy as Sender - with variable attributes

Former Member
0 Kudos

Hi Guys,

I am wondering how I could implement a generic XI Java proxy...

My goal is to specify the sender (service, ns, <b>interface</b> ...) dynamically and assign the corresponding payload directly to the proxy.

Unfortuantely I only find methods for configuring the receiver in the MesseageSepcifier interface - and not the sender. with <i>setPayload</i> I should be able to set any payload I guess.

Do I really need to use a WS client in order to dynamically set the sender or is there another way?

Thx in advance!

Helge

Accepted Solutions (1)

Accepted Solutions (1)

stefan_grube
Active Contributor
0 Kudos

Hi Helge,

could explain, why you cannat create a Java proxy for each interface and why you need different senders?

You can set the sender service name dynamically, check out for the methods of the interface MessageSpecifier. It is not mentioned in the online help, but it exists anyway.

Regards

Stefan

Former Member
0 Kudos

Hi Stefan,

the program is like a general purpose adapter. we have different files and each of it should be easily insertied into xi. Then we just want to use the directory to configure the connection since we do not need mappings etc.

I also thought that there should be some method like setSender since the help indicated sth. like that.

I will try. Thanks for the hint!

Regards,

Helge

stefan_grube
Active Contributor
0 Kudos

Here the methods:

setSenderPartyName(String)

setSenderService(String)

But there is no method for changing the interface name. This is hard coded in the proxy.

Regards

Stefan

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi ,

The Java Proxy is created with the Message type contained in the Message Interface whose Java proxy is created.

SAPXI will expect Payload in the metadata of the Message type being used. If you can make this generic then I think you can use it in multiple places.

Regards

Vijaya