uCosminexus Application Server, Web Service Development Guide
This section describes the initialization and destruction of the Web Service. This is applicable to both, POJO and EJB Web Services.
In the JAX-WS engine on the Web Service, when the J2EE server starts the J2EE application, the Web Service is initialized. Specifically, the following processing is executed:
When the initialization of the Web Service starts, the KDJW40001-I message is output in the log and standard output. If Web Service initialization ends normally, the KDJW40003-I message is output in the log and standard output. If an error occurs during Web Service initialization and if the initialization fails, the KDJW40002-E message and the error message that caused the error is output in the log and standard error output.
If an error occurs during Web Service initialization, an error is output in the log, but the startup of the J2EE application continues and ends normally. However, since the initialization failed, the deployed Web Service does not work. In this case, check if the KDJW40002-E message is output. If an error is output, correct the problem and deploy the Web Service again.
When starting a J2EE server, it might be difficult to investigate in a J2EE application why Web Service could not be initialized, when the deployed J2EE application is started automatically. In such cases, you can identify the J2EE application name and the context root name by checking logs shown in the section 39.3.1 Types of log, and operation logs of the J2EE server.
The following is an example of checking the output contents of the message KDJE39103-E including com.cosminexus.xml.ws.transport.http.servlet.WSServletContextListener:
0095 2009/12/18 13:48:36.471 HEJB 0125FEFA 004413EE KDJE39103-E An exception javax.xml.ws.WebServiceException was raised in notification of the listener class com.cosminexus.xml.ws.transport.http.servlet.WSServletContextListener. (J2EE application = Sample_application_fromwsdl, context root = /fromjava) |
When a log such as the one shown above is output, an attempt to initialize the Web Service within the WAR file that is associated with the context root name fromjava and included in the J2EE application Sample_application_fromwsdl will fail.
If there is a problem with the user program, basically an error corresponding to the message KDJE39103-E occurs. However, check the following error messages also, as and when required:
For the operation logs of the J2EE server, see 5.2 Log contents of Application Server in the uCosminexus Application Server Maintenance and Migration Guide. Also for the above messages, see 7.2. Messages from KDJE30000 to KDJE39999 in the manual uCosminexus Application Server Messages.
In the JAX-WS engine on the Web Service, when the J2EE server ends the J2EE application, the Web Service is destroyed. Specifically, the following processing is executed:
When the destruction of the Web Service starts, the KDJW40004-I message is output in the log and standard output. If Web Service destruction ends successfully, the KDJW40006-I message is output in the log and standard output. If an error occurs during Web Service destruction and if the destruction fails, the KDJW40015-E message and the error message that caused the error is output in the log and standard error output.
If an error occurs during Web Service destruction, an error is output in the log, but the end processing of the J2EE application continues and ends normally. In this case, check if the KDJW40015-E message is output and if an error is output, correct the problem.
All Rights Reserved. Copyright (C) 2013, Hitachi, Ltd.