About Question enthuware.ocejws.v6.2.32

Moderators: Site Manager, fjwalraven

Post Reply
sttaq0442
Posts: 27
Joined: Tue Nov 15, 2016 11:20 am
Contact:

About Question enthuware.ocejws.v6.2.32

Post by sttaq0442 »

Hi Frits,

I tried the following in NetBeans 8.2:

Code: Select all

@WebService(serviceName="LWS", endpointInterface="LogService", name="LS")
using GlassFish server for deployment. It appeared to append the portType name as well. So in this case the URL would be /log/LWS/LS.

Can you please confirm that for the purpose of exam we need to remember that the URL will always be like this: /rootContext/serviceName ?

Thanks

fjwalraven
Posts: 429
Joined: Tue Jul 24, 2012 2:43 am
Contact:

Re: About Question enthuware.ocejws.v6.2.32

Post by fjwalraven »

Interesting: the implementation in Glassfish seems to have changed over time!
Can you please confirm that for the purpose of exam we need to remember that the URL will always be like this: /rootContext/serviceName ?
Yes!

Regards,
Frits

javabean68
Posts: 31
Joined: Wed Mar 16, 2016 8:38 am
Contact:

Re: About Question enthuware.ocejws.v6.2.32

Post by javabean68 »

Hallo Frits,

here I would have expected the antwort 4 (/log/LogServiceImplService). I have read somewhere that if the @Webservice is on the SEI, the @Webservice on the SIB is ignored and then the URL would be SIB + "Service".

Is that instead wrong?

Thank you very much in advance
Regards
Fabio

fjwalraven
Posts: 429
Joined: Tue Jul 24, 2012 2:43 am
Contact:

Re: About Question enthuware.ocejws.v6.2.32

Post by fjwalraven »

Hi Fabio,
if the @Webservice is on the SEI, the @Webservice on the SIB is ignored
This is correct when it comes to which methods are exposed in the webservice.

But... for the attributes/elements of the @Webservice annotation it is a bit different (and tricky!)

This is from the specs JSR-181:
3.1 Service Implementation Bean
The implementation bean MAY reference a service endpoint interface by using the @WebService.endpointInterface annotation. If the implementation bean references a service endpoint interface, it MUST implement all the methods on the service endpoint interface. If the implementation bean references a service endpoint interface, that service endpoint interface is used to determine the abstract WSDL contract (portType and bindings). In this case, the service implementation bean MUST NOT include any JSR-181 annotations other than @WebService and @HandlerChain. In addition, the @WebService annotation MUST NOT include the name annotation element.

3.2 Service Endpoint Interface
The service endpoint interface MUST NOT include the JSR-181 annotation elements portName, serviceName and endpointInterface of the annotation @WebService.
Regards,
Frits

Post Reply

Who is online

Users browsing this forum: No registered users and 19 guests