[jboss-user] [JBossWS] - Service endpoint and client generation problem

joestevens do-not-reply at jboss.com
Wed May 21 18:11:01 EDT 2008

   I'm working on a small ws project to get my feet wet.  Things were moving along, but got complicated enough that it was time to add some automation to the build.  I'm using the bottom-up approach for my endpoint as outlined in the JAX-WS Tools section of the wiki.  I wrote the implementation, added the annotations, and the wsdl got generated.  Worked great.

Next, I decided to use the wsdl to generate client support code.  I set up an ant task using wsconsume, and everything generated fine.  So, I created a little test client using the generated code, ran it, and everything worked.  Sweet.  Writing software is easy.

As soon as that thought crossed my mind, the software gods decided to punish me for my hubris.  If I clean out the build and recompile and regenerate, the build breaks.  In order to generate the client support classes, wsconsume needs the wsdl.  In order to generate the wsdl, wsprovide needs the endpoint class file.  In  order to compile the endpoint the client support classes are needed because the client depends on them and they are in the same source tree.  So, I have a chicken and egg problem.

The only way that jumps to mind to fix this is to have separate source trees for the endpoint and the client code.  That feels kind of clunky.  It seems reasonable to have an endpoint implementation, client support classes, and a client in the same source tree.  Do most people separate client and server or are there other solutions I'm not thinking of?

If you're still reading, thanks.  Any ideas are appreciated.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4152498#4152498

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4152498

More information about the jboss-user mailing list