cancel
Showing results for 
Search instead for 
Did you mean: 

Consuming BRM Webservice in Web Dynpro on NW 7.3

bernd_speckmann
Contributor
0 Kudos

Hello,

I've got a big problem comsuming a Business Rules Management (BRM) Webservice (Netweaver 7.3) in my Web Dynpro app.

In WSNavigator the webservice is running fine and fully functional.

I created a custom controller by using the "apply template" function and selecting the mentioned webservice, which I have imported before.

The following methods were created within the custom controller: executeInvokeRules() and initRequest_InvokeRules() .

When I just execute the webservice the error, that there are mandatory input parameters occures. That's OK!

But when I want to set the values to the attribtues in my custom controller, the following error occures:


com.sap.tc.webdynpro.progmodel.context.ContextModelException: Node(ConfigureAngebot/PreisfindungRController.Request_InvokeRules.RequestAufpreisfindung.Aufpreise_1.AufpreiseType_1.Preise_1, class=de.mycomp.mydevision.bau.angebot.admin.wd.wd.comp.configureangebot.wdp.IPublicPreisfindungRController$IPreise_1Node): <modelObject class="de.mycomp.mydevision.bau.angebot.admin.wd.wd.models.preisfindungr.AufpreiseType_Sequence1__"><target roleName="Preise"></target></modelObject> delivered no object for supplying relation role Preise, but the relation cardinality requires one
  at com.sap.tc.webdynpro.progmodel.context.DataNode.supplyRelation(DataNode.java:229)

Any help would be apprecited.

Thanks ahead,

Bernd

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hello Bernd,

this error is a singleton characteristic issue. You get this error if you try to use singleton context node without setting lead selection before. If you are using singleton context nodes and want to set attributes, you have to work like this:

ISingletonNode singletonNode = wdContext.createAndAddSingletonNode();
wdContext.nodeSingletonParent.setLeadSelection(singletonParent.index());
wdContext.currentSingletonParent.setExampleValue("Test");

For Lead selection you can also use constant IWDNode.LEAD_SELECTION

BR , Alex

Former Member
0 Kudos

Hi,

Dont use apply template for web service ,Create the model and execute web service using your own code

Regards

Suresh

bernd_speckmann
Contributor
0 Kudos

Hi,

my own code does the same as the code created with the custom controller. Could you please provide a code example?

Regards, Bernd