- This topic has 9 replies, 4 voices, and was last updated 16 years, 2 months ago by
cporter71.
-
AuthorPosts
-
Teun HoogendoornMemberHi,
I’m trying to run the JAXWS annotation processor in MyEclipse 6. I’ve added
jaxws-tools.jar to the factory path. The .apt_generated folder is generated and
the package folders of my web service are added. But no files are generated.
No errors are reported in the problems view. Can you help me?Thanks,
Teun Hoogendoorn
January 12, 2009 at 5:17 am #293349
Teun HoogendoornMemberHi,
Some extra info. Running the wsgen task manually generates the files I’m looking for. But this
means I’ve to run an ant task on every change of my webservice. Can this be done
automatically?Thanks,
Teun Hoogendoorn
January 14, 2009 at 12:01 pm #293498
Brian FernandesModeratorTeun,
I assume you’re trying bottom up WS generation. Our tools should automatically setup the annotation processor and enable annotation processing for your project. The classes you refer to should be automatically generated in the .apt-generated folder.
If you go to your project properties > Java Compiler > Annotation Processing is Annotation processing enabled? On the Annotation Processing > Factory Path page, you should see the following: MYECLIPSE_WS_TOOLS_HOME/webservices-tools.jar
Do you see any errors logged in the Error Log view when you run the bottom up process?Can you tell me how you setup your web service project? Did you set it up with the web service project wizard or was this a Java EE 5 web project? To test, can you try making the above settings manually if they don’t already exist for your project? Alternatively you could try in a fresh web service project.
Finally, if you are using MyEclipse 6.0, I would recommend moving to MyEclipse 7 if possible or at least MyEclipse 6.6 if you need to stay on Europa.
January 15, 2009 at 1:16 am #293524
Teun HoogendoornMemberHi Brian,
Thanks for your response.
I’ve created a java file with the following code:
@WebService(name=”Hello”, serviceName=”HelloService”, targetNamespace=”http://www.example.com”)
public class Hello
{
@WebMethod public String hello(@WebParam(name=”name”) String s)
{
return s;
}
}I’ve done this in an existing Java EE 5 web project. I’ve added the endpoint in sun-jaxws.xml and tweaked web.xml. With my own ant task (using com.sun.tools.ws.ant.WsGen) to generate the webservice there’s no problem, but I’ve to run this manually.
Annotation processing is turned on. But the variable you mention does not exist. There is a variable MYECLIPSE_XFIRE_DATA_HOME but no MYECLIPSE_WS_TOOLS_HOME (is this a MyEclipse 6 variable?). But I’ve added jaxws-tools.jar to the factory path instead (running in and out batch mode). But this does not work. I shall try to upgrade to MyEclipse 7 in the coming weeks, to see if my problem is solved.
Thanks,
Teun Hoogendoorn
March 23, 2009 at 10:33 am #296542
Teun HoogendoornMemberHi,
Finally upgraded to MyEclipse 7.1.1. It works a little bit better now. On project clean the files are generated, but not after saving a file. I’ve to clean
after every change (takes a lot of time).Thanks,
Teun Hoogendoorn
March 23, 2009 at 11:58 am #296552
Brian FernandesModeratorTeun,
On project clean the files are generated, but not after saving a file. I’ve to clean after every change (takes a lot of time).
Just to confirm, you are saying that files in the .apt_generated folder are only being updated when you clean your project, right?
March 24, 2009 at 2:51 am #296588
Teun HoogendoornMemberHi Brian,
Yes, only when I clean the project.
Thanks again,
Teun Hoogendoorn
April 20, 2009 at 10:22 am #297718
fabioParticipanthy and thanks in advice
i’m using myeclipse 7.1.1
Version: 7.1.1
Build id: 7.1.1-20090310and i’m trying to follow the tutorial
Developing JAX-WS Web Services & Clients Tutorial
the only differences between my project and the tutorial is the package name.
and at the end of step 5
getting the infamous error:!ENTRY org.eclipse.core.jobs 4 2 2009-04-20 17:01:46.411
!MESSAGE An internal error occurred during: “Generating JAX-WS Web Services”.
!STACK 0
com.sun.xml.ws.model.RuntimeModelerException: runtime modeler error: Wrapper class com.t.ws.jaxws.Add is not found. Have you run APT to generate them?
at com.sun.xml.ws.model.RuntimeModeler.getClass(RuntimeModeler.java:287)
at com.sun.xml.ws.model.RuntimeModeler.processDocWrappedMethod(RuntimeModeler.java:596)
at com.sun.xml.ws.model.RuntimeModeler.processMethod(RuntimeModeler.java:543)
at com.sun.xml.ws.model.RuntimeModeler.processClass(RuntimeModeler.java:371)
at com.sun.xml.ws.model.RuntimeModeler.buildRuntimeModel(RuntimeModeler.java:258)
at com.sun.tools.ws.wscompile.WsgenTool.buildModel(WsgenTool.java:225)
at com.sun.tools.ws.wscompile.WsgenTool.run(WsgenTool.java:124)
at com.genuitec.eclipse.ws.jaxws.JaxWSBUJob.wsGen(JaxWSBUJob.java:224)
at com.genuitec.eclipse.ws.jaxws.JaxWSBUJob.run(JaxWSBUJob.java:124)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)i’ve checked all things i’m able to find on we-forum, all compiler settings are ok, they are setted as said in some other post. annotation processing is enabled, factory
path contains the ws tool jar
build automatically is checked.
But the folder .apt_generated is always empty.
i’m using jdk 1.6.12
code compliance setted to 1.5.any idea?
April 21, 2009 at 6:30 am #297744
fabioParticipantsome news
i’ve downloaded the sample jax-ws project from myeclipse .
if i try to add some new things to the example it works.but i can’t figure out what i’m doing wrong, because, if i try to create e new webservice project it still doesn’t work.
May 7, 2009 at 11:25 am #298252
cporter71MemberI would love to see this fixed (err….working properly?). My process tends to be:
> create projects using mvn eclipse:eclipse
> for a given web-service, add ‘web-project capabilities’
> enable annotation processing – add webservices-tools.jarAt this point mye generates the *.class files for me in .apt_generated. However, anytime I clean or do anything to trigger a build the generated files are wiped. I must go back to ‘annotation procession’ and disable, then apply, then re-enable apply. That works with some version of consistency. What I have been doing as a work around is copying the source files from .apt_generated into my project.
This would be a great feature – please fix or show me the error of my ways!
env: jaxws services/tomcat/osx
myeclipse: Version: 7.1.1 (Build id: 7.1.1-20090310)Thanks –
cporrter -
AuthorPosts