- This topic has 3 replies, 2 voices, and was last updated 14 years ago by s2dev.
-
AuthorPosts
-
s2devMemberHi,
We are trying to generate Websphere-specific JAX-RPC webservices using a bottom-up approach. When any method in the java file throws an application-exception – the webservice generation fails with the following error:The Java method in question is:
public Person getPersonDetails(int id) throws InvalidPersonException { return new Person(); }
and the Exception class is defined as:
public class InvalidPersonException extends Exception { private static final long serialVersionUID = 1L; private int errCode; private String errMessage; public InvalidPersonException(int errCode, String errMessage, Throwable cause) { super(errMessage, cause); this.errCode = errCode; this.errMessage = errMessage; } // Omitted: Getters and Setters }
[Note: Same error occurs even if we have no extra attributes in Exception class]
RAD7 is able to generated the webservice from the same set of test classes without any error.
Pls. advice …..
Thanks and Regards.
Environment: WinXP (or Ubuntu Linux) | WAS7 | MyEclipse on Sun/Oracle JDK 1.6 | Project JDK pointing to IBM JDK bundled with WAS7
support-swapnaModerators2dev,
Please paste your installation details here from MyEclipse > Installation Summary > Installation Details.
I assume that the webservice is created when there is no java application exception. Right? Can you verify the same?
Clear the .log file which is at <workspace dir>/.metadata folder and try generating the webservice. If you see any specific errors in the .log file, please paste them here.
s2devMemberThanks for the reply. Pls. find the requested details inline below (the forums don’t seem to allow attachments :()
(1)
@support-swapna wrote:Please paste your installation details here from MyEclipse > Installation Summary > Installation Details.
The installation details are as follows:
*** Date: Thursday, December 16, 2010 6:08:50 PM GMT+05:30 ** System properties: OS=WindowsXP OS version=5.1.0 Java version=1.6.0_13 *** MyEclipse details: MyEclipse Blue Edition Version: 8.6 Blue Build id: 8.6-Blue-20100723 *** Eclipse details: MyEclipse Blue Edition Version: 8.6 Blue Build id: 8.6-Blue-20100723 Eclipse Platform Version: 3.5.2.R35x_v20100210-0800-9hEiFzmFst-TiEn9hNYgDWg1XN8ulH_JvCNGB Build id: M20100211-1343 Eclipse Java Development Tools Version: 3.5.2.r352_v20100108-7r88FEwFI0WTuoBl0iaG0tyhfZH6 Build id: M20100211-1343 Eclipse Plug-in Development Environment Version: 3.5.2.R35x_v20100119-7Z7_FA2FDX-aXQYWqYDBz-z0qufo Build id: M20100211-1343 Eclipse Graphical Editing Framework GEF Version: 3.5.2.v20100111-1352-777928194B66D5D476C33B2A Build id: 201001111753 Eclipse RCP Version: 3.5.2.R35x_v20100119-9SA0FxwFnoCU5XxWItFdXXb27BA6 Build id: M20100211-1343 Eclipse startup command=-os win32 -ws win32 -arch x86 -showsplash -launcher D:\Program Files\Genuitec\myeclipse-blue.exe -name Myeclipse-blue --launcher.library D:\Program Files\Genuitec\Common/plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.0.200.v20090519\eclipse_1206.dll -startup D:\Program Files\Genuitec\Common/plugins/org.eclipse.equinox.launcher_1.0.201.R35x_v20090715.jar -install D:/Program Files/Genuitec -data D:\dev\Server\RAD Alternative\support details\MyEclipse_Workspace_Evaluation -launcher D:\Program Files\Genuitec\myeclipse-blue.exe -install D:/Program Files/Genuitec -vm D:\Program Files\Genuitec\Common/binary/com.sun.java.jdk.win32.x86_1.6.0.013/jre/bin/client/jvm.dll
(2)
@support-swapna wrote:I assume that the webservice is created when there is no java application exception. Right? Can you verify the same?
Yes – if none of the methods have any throws clause – the webservice is generated correctly. The problem only exhibits itself when there is a method in the class that throws an exception.
(3)
@support-swapna wrote:Clear the .log file which is at <workspace dir>/.metadata folder and try generating the webservice. If you see any specific errors in the .log file, please paste them here.
Here is the exception stack from the log:
!ENTRY com.genuitec.eclipse.ws.blue 1 0 2010-12-16 18:36:51.276 !MESSAGE !STACK 0 java.io.FileNotFoundException: Source 'D:\MyEclipse_TestService\TestWeb\.myeclipse\wsgeneration\wso2\WEB-INF\ibm-webservices-bnd.xmi' does not exist at org.apache.commons.io.FileUtils.copyFile(FileUtils.java:636) at org.apache.commons.io.FileUtils.copyFile(FileUtils.java:606) at com.genuitec.eclipse.ws.blue.jaxrpc.JAXRPCJob.manageIBMWSFile(JAXRPCJob.java:774) at com.genuitec.eclipse.ws.blue.jaxrpc.JAXRPCJob.manageXMLFiles(JAXRPCJob.java:634) at com.genuitec.eclipse.ws.blue.jaxrpc.JAXRPCJob.run(JAXRPCJob.java:246) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55) !ENTRY com.genuitec.eclipse.ws.blue 1 0 2010-12-16 18:36:51.323 !MESSAGE !STACK 0 java.io.FileNotFoundException: Source 'D:\MyEclipse_TestService\TestWeb\.myeclipse\wsgeneration\wso2\WEB-INF\ibm-webservices-ext.xmi' does not exist at org.apache.commons.io.FileUtils.copyFile(FileUtils.java:636) at org.apache.commons.io.FileUtils.copyFile(FileUtils.java:606) at com.genuitec.eclipse.ws.blue.jaxrpc.JAXRPCJob.manageIBMWSFile(JAXRPCJob.java:774) at com.genuitec.eclipse.ws.blue.jaxrpc.JAXRPCJob.manageXMLFiles(JAXRPCJob.java:641) at com.genuitec.eclipse.ws.blue.jaxrpc.JAXRPCJob.run(JAXRPCJob.java:246) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55) !ENTRY org.eclipse.core.jobs 4 2 2010-12-16 18:36:51.433 !MESSAGE An internal error occurred during: "Generating JAX-RPC Web Services". !STACK 0 java.lang.IllegalArgumentException: Parameter 'directory' is not a directory at org.apache.commons.io.FileUtils.listFiles(FileUtils.java:292) at org.apache.commons.io.FileUtils.listFiles(FileUtils.java:377) at com.genuitec.eclipse.ws.blue.jaxrpc.JAXRPCJob.manageXMLFiles(JAXRPCJob.java:647) at com.genuitec.eclipse.ws.blue.jaxrpc.JAXRPCJob.run(JAXRPCJob.java:246) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
TIA
s2devMemberSwapna,
Sorry for the bump – but is there any update / solution to the above ?Also – if I may add another question related to Websphere-engine web-services here:
(2) WAS Java2WSDL supports additional parameters (http://is.gd/jd1wV) – e.g. “-extraClasses” to supply additional classes (useful when generating for polymorphism scenarios).Is there any way to supply such additional information (in particular extraClasses for now) in MyEclipse ? We know even RAD doesnt have this – but the command-line supports – so thought it was worth asking ….
Thanks and Regards.
-
AuthorPosts