You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Adriana Verdejo <ad...@gmail.com> on 2008/06/04 11:48:21 UTC
Problem using java2wsdl
Hi all,
I am new using axis and I am very lost. I would like to generate my wsdl
from my java interface. I have used the axis plugin for eclipse (axis 2 code
generator) but I find always this error message: "An error occured while
completing process -java.lang.reflect.InvocationTargetException". I don't
know what is wrong. Because of that I tried to do it by command..
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
eu.myproject.myComponent.myService
Using AXIS2_HOME: C:\axis2-1.2\axis2-1.2
Using JAVA_HOME: C:\Archivos de programa\Java\jre1.5.0_11
And I get this error:
An error occured while generating codejava.lang.ClassNotFoundException:
eu.myproject.myComponent.myService
My class is in my workspace. How I should give this information to axis?
Could you please help me? Thanks in advance.
Best regards,
Adriana.
Re: Problem using java2wsdl
Posted by pierre betz <pi...@gmail.com>.
same answer :) or try with your path beetwen " " like "c:\document
and... "
2008/6/4 Perez Arbulu, Ibai <i....@ibermatica.com>:
> I Would try with a different classpath.
>
>
>
> "Documents and settings" is not advisable at all.
> ------------------------------
>
> *De:* Adriana Verdejo [mailto:adrianaverdejo@gmail.com]
> *Enviado el:* Miércoles, 04 de Junio de 2008 05:23 a.m.
> *Para:* axis-user@ws.apache.org
> *Asunto:* RE: Problem using java2wsdl
>
>
>
> Dear Pierre,
>
>
>
> thanks for your fast answer, but I did it before and the error was the
> same..
>
>
>
> I mean...
>
>
>
> C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn C:\Documents
> and
> Settings\adriana\workspace\PruebaWSDL\bin\eu\myproject\mycomponent\myService
>
> Using AXIS2_HOME: C:\axis2-1.2\axis2-1.2
> Using JAVA_HOME: C:\Archivos de programa\Java\jre1.5.0_11
> An error occured while generating codejava.lang.ClassNotFoundException:
> C:\Documents
>
> My interface is like that..
>
>
>
>
>
> package eu.myproject.mycomponent;
>
>
>
> import myproject.mycomponent.mymodule1.otherService1;
> import myproject.mycomponent.mymodule2.otherService2;
>
>
>
> public interface myService extends otherService1, otherService2 {
>
>
>
> }
>
>
>
> Thanks,
>
>
>
> Adriana.
>
>
> ------------------------------
>
> *De:* pierre betz [mailto:piebetz@gmail.com]
> *Enviado el:* miércoles, 04 de junio de 2008 12:04
> *Para:* axis-user@ws.apache.org
> *Asunto:* Re: Problem using java2wsdl
>
> a codejava.lang.ClassNotFoundException: eu.myproject.myComponent.myService
> is generated when the class is not found.
>
> you are using :
>
> C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
> eu.myproject.myComponent.myService
>
>
>
> which describe that you class myService is in the folder
> C:\axis2-1.2\axis2-1.2\bin\eu\myproject\myComponent.
>
> are you sure that you pu the class in this folder ?
> if not, you have to explain where is you class, like :
>
>
>
> C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
> yourparentclassdirectory\myService
>
>
>
> like : if my class is located here : c:\myproject\myClass.class
>
>
>
> C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
> c:\myproject\myClass
>
>
>
> does it work?
>
>
>
>
>
>
>
>
>
>
>
RE: Problem using java2wsdl
Posted by Adriana Verdejo <ad...@gmail.com>.
Really, I had testing something as simple as that (please find attached the
simple project...)
_____
De: pierre betz [mailto:piebetz@gmail.com]
Enviado el: miércoles, 04 de junio de 2008 12:46
Para: axis-user@ws.apache.org
Asunto: Re: Problem using java2wsdl
i tried the same, and I think it's maybe your code which have a problem.
I'm not an expert in java2wsdl, but maybe the problem is in your code files,
in fact the interface is not a class, so maybe you need to put the class
path after cn, and not the interface.
as I don't have your files, I can't test myself.
your class will implement this interface, so maybe try to find out the
problem by this way.
Re: Problem using java2wsdl
Posted by pierre betz <pi...@gmail.com>.
i tried the same, and I think it's maybe your code which have a problem.
I'm not an expert in java2wsdl, but maybe the problem is in your code files,
in fact the interface is not a class, so maybe you need to put the class
path after cn, and not the interface.
as I don't have your files, I can't test myself.
your class will implement this interface, so maybe try to find out the
problem by this way.
RE: Problem using java2wsdl
Posted by Adriana Verdejo <ad...@gmail.com>.
I have copied my folder in C:\ and it is the same...
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
C:\PruebaWSDL\bin\eu\myproject\mycomponent\myService
Using AXIS2_HOME: C:\axis2-1.2\axis2-1.2
Using JAVA_HOME: C:\Archivos de programa\Java\jre1.5.0_11
An error occured while generating codejava.lang.ClassNotFoundException:
C:\PruebaWSDL\bin\eu\myproject\mycomponent\myService
_____
De: Perez Arbulu, Ibai [mailto:i.perez.arbulu@ibermatica.com]
Enviado el: miércoles, 04 de junio de 2008 12:28
Para: axis-user@ws.apache.org
Asunto: RE: Problem using java2wsdl
I Would try with a different classpath.
Documents and settings is not advisable at all.
_____
De: Adriana Verdejo [mailto:adrianaverdejo@gmail.com]
Enviado el: Miércoles, 04 de Junio de 2008 05:23 a.m.
Para: axis-user@ws.apache.org
Asunto: RE: Problem using java2wsdl
Dear Pierre,
thanks for your fast answer, but I did it before and the error was the
same..
I mean...
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn C:\Documents and
Settings\adriana\workspace\PruebaWSDL\bin\eu\myproject\mycomponent\myService
Using AXIS2_HOME: C:\axis2-1.2\axis2-1.2
Using JAVA_HOME: C:\Archivos de programa\Java\jre1.5.0_11
An error occured while generating codejava.lang.ClassNotFoundException:
C:\Documents
My interface is like that..
package eu.myproject.mycomponent;
import myproject.mycomponent.mymodule1.otherService1;
import myproject.mycomponent.mymodule2.otherService2;
public interface myService extends otherService1, otherService2 {
}
Thanks,
Adriana.
_____
De: pierre betz [mailto:piebetz@gmail.com]
Enviado el: miércoles, 04 de junio de 2008 12:04
Para: axis-user@ws.apache.org
Asunto: Re: Problem using java2wsdl
a codejava.lang.ClassNotFoundException: eu.myproject.myComponent.myService
is generated when the class is not found.
you are using :
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
eu.myproject.myComponent.myService
which describe that you class myService is in the folder
C:\axis2-1.2\axis2-1.2\bin\eu\myproject\myComponent.
are you sure that you pu the class in this folder ?
if not, you have to explain where is you class, like :
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
yourparentclassdirectory\myService
like : if my class is located here : c:\myproject\myClass.class
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
c:\myproject\myClass
does it work?
RE: Problem using java2wsdl
Posted by "Perez Arbulu, Ibai" <i....@ibermatica.com>.
I Would try with a different classpath.
"Documents and settings" is not advisable at all.
________________________________
De: Adriana Verdejo [mailto:adrianaverdejo@gmail.com]
Enviado el: Miércoles, 04 de Junio de 2008 05:23 a.m.
Para: axis-user@ws.apache.org
Asunto: RE: Problem using java2wsdl
Dear Pierre,
thanks for your fast answer, but I did it before and the error was the same..
I mean...
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn C:\Documents and Settings\adriana\workspace\PruebaWSDL\bin\eu\myproject\mycomponent\myService
Using AXIS2_HOME: C:\axis2-1.2\axis2-1.2
Using JAVA_HOME: C:\Archivos de programa\Java\jre1.5.0_11
An error occured while generating codejava.lang.ClassNotFoundException: C:\Documents
My interface is like that..
package eu.myproject.mycomponent;
import myproject.mycomponent.mymodule1.otherService1;
import myproject.mycomponent.mymodule2.otherService2;
public interface myService extends otherService1, otherService2 {
}
Thanks,
Adriana.
________________________________
De: pierre betz [mailto:piebetz@gmail.com]
Enviado el: miércoles, 04 de junio de 2008 12:04
Para: axis-user@ws.apache.org
Asunto: Re: Problem using java2wsdl
a codejava.lang.ClassNotFoundException: eu.myproject.myComponent.myService is generated when the class is not found.
you are using :
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn eu.myproject.myComponent.myService
which describe that you class myService is in the folder C:\axis2-1.2\axis2-1.2\bin\eu\myproject\myComponent.
are you sure that you pu the class in this folder ?
if not, you have to explain where is you class, like :
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn yourparentclassdirectory\myService
like : if my class is located here : c:\myproject\myClass.class
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn c:\myproject\myClass
does it work?
RE: Problem using java2wsdl
Posted by Adriana Verdejo <ad...@gmail.com>.
Dear Pierre,
thanks for your fast answer, but I did it before and the error was the
same..
I mean...
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn C:\Documents and
Settings\adriana\workspace\PruebaWSDL\bin\eu\myproject\mycomponent\myService
Using AXIS2_HOME: C:\axis2-1.2\axis2-1.2
Using JAVA_HOME: C:\Archivos de programa\Java\jre1.5.0_11
An error occured while generating codejava.lang.ClassNotFoundException:
C:\Documents
My interface is like that..
package eu.myproject.mycomponent;
import myproject.mycomponent.mymodule1.otherService1;
import myproject.mycomponent.mymodule2.otherService2;
public interface myService extends otherService1, otherService2 {
}
Thanks,
Adriana.
_____
De: pierre betz [mailto:piebetz@gmail.com]
Enviado el: miércoles, 04 de junio de 2008 12:04
Para: axis-user@ws.apache.org
Asunto: Re: Problem using java2wsdl
a codejava.lang.ClassNotFoundException: eu.myproject.myComponent.myService
is generated when the class is not found.
you are using :
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
eu.myproject.myComponent.myService
which describe that you class myService is in the folder
C:\axis2-1.2\axis2-1.2\bin\eu\myproject\myComponent.
are you sure that you pu the class in this folder ?
if not, you have to explain where is you class, like :
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
yourparentclassdirectory\myService
like : if my class is located here : c:\myproject\myClass.class
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
c:\myproject\myClass
does it work?
Re: Problem using java2wsdl
Posted by pierre betz <pi...@gmail.com>.
a codejava.lang.ClassNotFoundException: eu.myproject.myComponent.myService
is generated when the class is not found.
you are using :
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn eu.myproject.
myComponent.myService
which describe that you class myService is in the folder
C:\axis2-1.2\axis2-1.2\bin\eu\myproject\myComponent.
are you sure that you pu the class in this folder ?
if not, you have to explain where is you class, like :
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
yourparentclassdirectory\myService
like : if my class is located here : c:\myproject\myClass.class
C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
c:\myproject\myClass
does it work?
Re: Problem using java2wsdl
Posted by Paul Fremantle <pz...@gmail.com>.
Adriana
Maybe you don't even need to use java2wsdl. Are you deploying a Java
class as a service? If so, then Axis2 automatically generates the WSDL
for you.
Paul
On Wed, Jun 4, 2008 at 10:48 AM, Adriana Verdejo
<ad...@gmail.com> wrote:
> Hi all,
>
> I am new using axis and I am very lost. I would like to generate my wsdl
> from my java interface. I have used the axis plugin for eclipse (axis 2 code
> generator) but I find always this error message: "An error occured while
> completing process -java.lang.reflect.InvocationTargetException". I don't
> know what is wrong. Because of that I tried to do it by command..
>
>
> C:\axis2-1.2\axis2-1.2\bin>java2wsdl -of myService.wsdl -cn
> eu.myproject.myComponent.myService
>
> Using AXIS2_HOME: C:\axis2-1.2\axis2-1.2
>
> Using JAVA_HOME: C:\Archivos de programa\Java\jre1.5.0_11
>
>
>
> And I get this error:
>
>
>
> An error occured while generating codejava.lang.ClassNotFoundException:
> eu.myproject.myComponent.myService
>
>
>
> My class is in my workspace. How I should give this information to axis?
>
>
>
> Could you please help me? Thanks in advance.
>
>
> Best regards,
>
> Adriana.
--
Paul Fremantle
Co-Founder and CTO, WSO2
Apache Synapse PMC Chair
OASIS WS-RX TC Co-chair
blog: http://pzf.fremantle.org
paul@wso2.com
"Oxygenating the Web Service Platform", www.wso2.com
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org