Re: wsdl reference question
Abraham Washington wrote: sorry, should have included the code. this is just the calculator-ws-webapp composite (which is below). i added this code: which exposes the CalculatorService. but, now the wsdl has operations like: setAddService setDivideService i don't want to expose the methods to the outside world. is there a way around that ? > Just put @Remotable on the CalculatorService interface. Without this, the class is introspected to derive the WSDL service definition. With this, only the interface will be introspected. Simon thx abe http://www.osoa.org/xmlns/sca/1.0"; targetNamespace="http://sample"; xmlns:sample="http://sample"; name="Calculator"> http://localhost:8080/sample-calculator-ws-webapp/AddServiceComponent"/> - Original Message From: Mike Edwards <[EMAIL PROTECTED]> To: tuscany-user@ws.apache.org Sent: Wednesday, April 30, 2008 4:41:26 AM Subject: Re: wsdl reference question Abraham Washington wrote: hi all, i have a service that has a reference to another service.� so, in my impl class there's a setter method for the reference.�� when the app is deployed, the wsdl generates the setter method operation, thus making it available to be invoked (not a good thing).� is there a way around this ? thx abe Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ Hi Abe, Can you explain what your app is doing in some more detail - maybe post some code and the composite file? If you have declared a reference in your code, with a setter method, then I would expect the setter method to get called at runtime with the reference proxy for the target service that you configure in your composite file. For the setter method to get included in the WSDL generated for the service offered by the component, then: a) presumably you are not marking the service offered by the implementation code, so that the defaulting process is happening - you do this by using the @Service annotation b) also, I suspect that your class does not say something like public fooClass implements barInterface { ... } - since the default service generation will look at the barInterface to generate the WSDL for the service. If there is no "implements" clause then the SCA code has little to go on as to which methods should be included. In this case, as the SCA Java Client & Implementation specification says: "If none of the implemented interfaces is remotable, then by default the implementation offers a single service whose type is the implementation class." I recommend that you consider using one of the above techniques to control which class methods are used for the operations of the Service interface. Yours, Mike. Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
Re: wsdl reference question
Hi, When you promote a service, you can further configure the interface which can be a subset of the operations of the original CalculatorService. The XML could look like: Thanks, Raymond -- From: "Abraham Washington" <[EMAIL PROTECTED]> Sent: Wednesday, April 30, 2008 8:25 AM To: Subject: Re: wsdl reference question sorry, should have included the code. this is just the calculator-ws-webapp composite (which is below). i added this code: promote="CalculatorServiceComponent"> which exposes the CalculatorService. but, now the wsdl has operations like: setAddService setDivideService i don't want to expose the methods to the outside world. is there a way around that ? thx abe http://www.osoa.org/xmlns/sca/1.0"; targetNamespace="http://sample"; xmlns:sample="http://sample"; name="Calculator">promote="CalculatorServiceComponent">name="CalculatorServiceComponent"> uri="http://localhost:8080/sample-calculator-ws-webapp/AddServiceComponent"/> target="SubtractServiceComponent"> target="MultiplyServiceComponent"> target="DivideServiceComponent"> - Original Message From: Mike Edwards <[EMAIL PROTECTED]> To: tuscany-user@ws.apache.org Sent: Wednesday, April 30, 2008 4:41:26 AM Subject: Re: wsdl reference question Abraham Washington wrote: hi all, i have a service that has a reference to another service.� so, in my impl class there's a setter method for the reference.�� when the app is deployed, the wsdl generates the setter method operation, thus making it available to be invoked (not a good thing).� is there a way around this ? thx abe Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ Hi Abe, Can you explain what your app is doing in some more detail - maybe post some code and the composite file? If you have declared a reference in your code, with a setter method, then I would expect the setter method to get called at runtime with the reference proxy for the target service that you configure in your composite file. For the setter method to get included in the WSDL generated for the service offered by the component, then: a) presumably you are not marking the service offered by the implementation code, so that the defaulting process is happening - you do this by using the @Service annotation b) also, I suspect that your class does not say something like public fooClass implements barInterface { ... } - since the default service generation will look at the barInterface to generate the WSDL for the service. If there is no "implements" clause then the SCA code has little to go on as to which methods should be included. In this case, as the SCA Java Client & Implementation specification says: "If none of the implemented interfaces is remotable, then by default the implementation offers a single service whose type is the implementation class." I recommend that you consider using one of the above techniques to control which class methods are used for the operations of the Service interface. Yours, Mike. Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
Re: wsdl reference question
sorry, should have included the code. this is just the calculator-ws-webapp composite (which is below). i added this code: which exposes the CalculatorService. but, now the wsdl has operations like: setAddService setDivideService i don't want to expose the methods to the outside world. is there a way around that ? thx abe http://www.osoa.org/xmlns/sca/1.0"; targetNamespace="http://sample"; xmlns:sample="http://sample"; name="Calculator"> http://localhost:8080/sample-calculator-ws-webapp/AddServiceComponent"/> - Original Message From: Mike Edwards <[EMAIL PROTECTED]> To: tuscany-user@ws.apache.org Sent: Wednesday, April 30, 2008 4:41:26 AM Subject: Re: wsdl reference question Abraham Washington wrote: > hi all, i have a service that has a reference to another service.� so, > in my impl class there's a setter method for the reference.�� when the > app is deployed, the wsdl generates the setter method operation, thus > making it available to be invoked (not a good thing).� > is there a way around this ? > thx abe > > > > > Be a better friend, newshound, and > know-it-all with Yahoo! Mobile. Try it now. > http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ Hi Abe, Can you explain what your app is doing in some more detail - maybe post some code and the composite file? If you have declared a reference in your code, with a setter method, then I would expect the setter method to get called at runtime with the reference proxy for the target service that you configure in your composite file. For the setter method to get included in the WSDL generated for the service offered by the component, then: a) presumably you are not marking the service offered by the implementation code, so that the defaulting process is happening - you do this by using the @Service annotation b) also, I suspect that your class does not say something like public fooClass implements barInterface { ... } - since the default service generation will look at the barInterface to generate the WSDL for the service. If there is no "implements" clause then the SCA code has little to go on as to which methods should be included. In this case, as the SCA Java Client & Implementation specification says: "If none of the implemented interfaces is remotable, then by default the implementation offers a single service whose type is the implementation class." I recommend that you consider using one of the above techniques to control which class methods are used for the operations of the Service interface. Yours, Mike. Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
Re: wsdl reference question
Abraham Washington wrote: hi all, i have a service that has a reference to another service.� so, > in my impl class there's a setter method for the reference.�� when the > app is deployed, the wsdl generates the setter method operation, thus > making it available to be invoked (not a good thing).� is there a way around this ? thx abe Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ Hi Abe, Can you explain what your app is doing in some more detail - maybe post some code and the composite file? If you have declared a reference in your code, with a setter method, then I would expect the setter method to get called at runtime with the reference proxy for the target service that you configure in your composite file. For the setter method to get included in the WSDL generated for the service offered by the component, then: a) presumably you are not marking the service offered by the implementation code, so that the defaulting process is happening - you do this by using the @Service annotation b) also, I suspect that your class does not say something like public fooClass implements barInterface { ... } - since the default service generation will look at the barInterface to generate the WSDL for the service. If there is no "implements" clause then the SCA code has little to go on as to which methods should be included. In this case, as the SCA Java Client & Implementation specification says: "If none of the implemented interfaces is remotable, then by default the implementation offers a single service whose type is the implementation class." I recommend that you consider using one of the above techniques to control which class methods are used for the operations of the Service interface. Yours, Mike.
wsdl reference question
hi all, i have a service that has a reference to another service. so, in my impl class there's a setter method for the reference. when the app is deployed, the wsdl generates the setter method operation, thus making it available to be invoked (not a good thing). is there a way around this ? thx abe Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ