cancel
Showing results for 
Search instead for 
Did you mean: 

"Target role name not defined" after change of WebService-interface

Former Member
0 Kudos

Hi experts,

I have implemented the usual project structure:

- EJB/EAR-DC implements a WebService

- One WebDynpro-DC imports the WebService as WebService-model

- Another WebDynpro-DC implements the ui using the model-DC

Everything works fine until I change the interface of some method of my WebService, lets say I add a new parameter. Of course I re-import the WebDynpro model and define relations for the new parameter. I can build all DCs without error and deploy them. Ok, but at runtime I get an error message:

"Target role name not defined"

What's going wrong here? I already tried to undeploy all DCs and re-deploy them. But still the same. As if there is some cache anywhere in the system that holds the old interface.

Here's the message:

java.lang.IllegalArgumentException: Target role name 'IdCoFilter' not defined for model class 'ActionFilterDTO'

at com.sap.tc.webdynpro.model.webservice.base.model.BaseGenericModelClass.retrieveTargetRoleInfo(BaseGenericModelClass.java:93)

at com.sap.tc.webdynpro.model.webservice.base.model.BaseGenericModelClass.setRelatedModelObject(BaseGenericModelClass.java:344)

at com.sap.tc.webdynpro.model.webservice.gci.WSTypedModelClass.setRelatedModelObject(WSTypedModelClass.java:69)

at com.karmann.dacc.wd.model.models.rep.ActionFilterDTO.setIdCoFilter(ActionFilterDTO.java:332)

at com.karmann.dacc.wd.ui.costoptcomp.wdbuddies.CostOptCompBuddy.initModelNodes(CostOptCompBuddy.java:290)

I can solve this problem only by restarting the server, which takes a lot of time, interrupts business and needles my admins. I can't imagine that this is the only solution. Thanks for each hint,

Christoph

Edited by: Christoph Schäfer on Jan 28, 2009 11:15 AM

Accepted Solutions (1)

Accepted Solutions (1)

former_member201361
Active Contributor
0 Kudos

Hi Chris,

Even we faced the same problem , when we added a new Parameter in the service .

we followed the below steps to get rid of this error message:

delete the web service and create a new one and expose it as web services and deploy the CAf project .

reimport the model and do the context mapping , this will solve ur problem .

Thanks and Regards

Former Member
0 Kudos

Hi Fazal,

thanks for this quick answer! What do you mean with "delete WebService"? I have already un-deployed it. Where can I delete a WebService explicitely?

By the way: When I call the changed WebService immediately after deployment in the WebService-Navigator of NWA, I can see the new parameter. And during re-import of the WebDynpro-model I can see the new parameter as well. So I suppose the problem not at WebService-side but at WebDynpro-side.

My admin has just suggested to restart the Java EE service "WebDynpro Runtime" after deployment of new WebService. I will try this when I will implement the next change and let you know about the result.

Regards,

Christoph

former_member201361
Active Contributor
0 Kudos

Hi Chris,

In CAF application, go to the Webservices. Delete the existing webservices(which you will get on exposesing the application services). Re-expose the application services and then generate,build and re-deploy.

In webdynpro then reimport the model using the new WSDL.

Thanks and Regards

junwu
Active Contributor
0 Kudos

Hi ,

I try your solution, restart the web dynpro runtime service.

it doesn't work.

Does anybody know the issue?

Best regards,

john

Answers (0)