users@glassfish.java.net

Newbie frustration - Cannot get web services to work

From: <glassfish_at_javadesktop.org>
Date: Mon, 30 Nov 2009 22:44:00 PST

I'm sure I had this working, but now it's just wont and I've spent 2 days trying to figure it out. I've read every tutorial, howto and document on the web I can find and nothing has fixed this.

I need to be able to generate a soap/http web service from a supplied wsdl.

Last week I wrote up a test wsdl with some basic types declared in a seperate xsd. Mostly complex types containing a few fields and one enum type. Nothing unusual as far as I can see.

Then I used eclipse to generate a top down java bean skeleton, and war/ear. I told the Gassfish server to deploy and all was wonderful. I was able to query the wsdl and access the services.

I then wanted to apply some basic authentication. Everything went wrong from there. In the end I wiped my eclipse workspace, reinstalled Glassfish several times, re-generated the project over and over and nothing works any more.

I'm currently using the Glassfish that Eclipse downloads which is a V3.

If I just generate a top down java bean web service and deploy it, Glassfish does not see it as a web service at all.

So I did some reading and applied the @WebService annotation. Now Glassfish sees it as a web service again, however if I try to access the wsdl, it generates a

java.security.PrivilegedActionException: com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 1 counts of IllegalAnnotationExceptions
com.dhcbank.www.banking.schema.TransactionEnum does not have a no-arg default constructor.

Exception. TransactionEnum being the java version of the xsd enum and does not have a no-arg constructor.

I cannot find a way to change this so I'm stuck with the following:

1. Glassfish used to see the generated java code (Impl, Skeleton, stub, etc) as a web service, but no longer does.

2. The only way to get it to see a web service is to add @WebService annotation (which I didn't have to before), but it crashes when I try to access it.

3. I cannot find a way to change the way the wsdl 2 java conversion is done.

4. I cannot figure out why Gashfish is no longer seeing the java code as a web service.

Grrr ! Help!

Derek
[Message sent by forum member 'drekka' ]

http://forums.java.net/jive/thread.jspa?messageID=373994