This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 91319 - When create JAX-RPC web service on gl9.1,JAX-WS is created instead
Summary: When create JAX-RPC web service on gl9.1,JAX-WS is created instead
Status: VERIFIED FIXED
Alias: None
Product: webservices
Classification: Unclassified
Component: JAX-WS (show other bugs)
Version: 5.x
Hardware: All All
: P1 blocker (vote)
Assignee: Martin Grebac
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-12-20 10:25 UTC by Jaroslav Pospisil
Modified: 2007-02-14 13:58 UTC (History)
6 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
screenshot 1 (94.29 KB, image/png)
2006-12-20 10:25 UTC, Jaroslav Pospisil
Details
screenshot 2 (95.98 KB, image/png)
2006-12-20 10:26 UTC, Jaroslav Pospisil
Details
Diff against release551 (25.89 KB, patch)
2007-02-01 17:14 UTC, Martin Grebac
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jaroslav Pospisil 2006-12-20 10:25:28 UTC
Build 200612180600,JDK1.6,Glassfish 9.1 b28

1)Start IDE with new userdir
2)Add Glassfish 9.1 in Runtime tab
3)Create new Web module on Glassfish,set J2EE version to 1.4
4)Create new web service
ERROR: Instead of JAX-RPC ws template is created JAX-WS template with
annotations and moreover if you right-click to invoke context menu,there's only
Web Service Client resources item.
Attaching screenshots of ws in editor and project properties with J2EE version
displayed.
Comment 1 Jaroslav Pospisil 2006-12-20 10:25:58 UTC
Created attachment 36835 [details]
screenshot 1
Comment 2 Jaroslav Pospisil 2006-12-20 10:26:29 UTC
Created attachment 36836 [details]
screenshot 2
Comment 3 Milan Kuchtiak 2006-12-21 09:57:25 UTC
Seems that one of the test in ClientInfo class was influenced by some recent
changes:

- JAX-WS upgrade
- GlassFish plugin changes (more likely)
Comment 4 Milan Kuchtiak 2006-12-21 10:00:57 UTC
Most likely the WizardProperties.JAX_VERSION property in ClientInfo is not set
correctly.
Comment 5 Lukas Jungmann 2007-01-02 10:28:24 UTC
Just for the record: in case of creating new ws from existing session bean
everything works as expected (JAX-RPC ws is created), in case of creating new ws
from scratch JAX-WS service is created.
Comment 6 Vince Kraemer 2007-01-05 00:21:07 UTC
I started to look at WebServiceCreator.generateWebService and my head started to
hurt.  The wrong generator is getting called at line 274... the if for this
block is confusing.
Comment 7 Roderico Cruz 2007-01-09 17:42:54 UTC
Per phone discussion with Milan, reassigning this to him. 
Comment 8 Roderico Cruz 2007-01-09 17:46:29 UTC
Here's a few notes. To support WSIT, the wizard determines if wsit is supported
by looking for the webservices-tools.jar. In AS 9.0, this jar is not present by
default, i.e., the user has to manually include it in the server's library.
However, in AS 9.1, this jar is always present, so the boolean representing WSIT
support is always true.
Comment 9 Martin Grebac 2007-01-10 10:10:21 UTC
 I'm asking myself whether this is really a problem. 

 I think no matter what, we will have to move away from supporting JAX-RPC. If I
understand it correctly, older (already created) JAX-RPC services work fine,
right? So, the only problem is that users cannot create new jax-rpc web services
if 9.1 is selected as a target server.

If 9.0 is selected, JAX-RPC services are created just fine, so current behaviour
is correct.

If Tomcat is selected, the current behaviour is correct as well - if WSIT is
there, JAX-WS non-jsr109 services are created, if WSIT is not there, JAX-RPC is
created.

So, any objections why this cannot considered as a correct behaviour?
Comment 10 Jaroslav Pospisil 2007-01-10 10:24:19 UTC
I think this is problem,since NB5.5.1 is nearly identical with NB5.5 and there
is support for JAX-RPC,so it should be the same for both glassfishes. My biggest
and most important objection is,that when user decides to create something and
somenthing very different is created (as in this case) then it's serious bug and
we have to fix it somehow.
I already discussed this with Milan and it seems this could be corrected by
simle UI change in the wizard, so why don't to do it? 
Comment 11 tamiro 2007-01-10 14:01:24 UTC
There is a big difference in GFs v1 versus v2. The latter has WSIT (with 
JAX-WS 2.1) integrated. If a customer chooses to download GF v2, who 
knows what they expect, but if we in the GF community are commuicating 
where GF is going, the customer should expect JAX-WS, not JAX-RPC. 
Maybe there could be an option added to the GUI to give customers a choice, 
but do we really want to encourage continued use of an old API going forward in
creating NEW apps on the NEW GF v2? JAX-WS 2.1 is a huge improvement that 
we want to promote. At the very least, the default should be to use JAX-WS 
and if there is an option to use JAX-RPC is should be presented with caveats 
that this API is at the end of its life. 
Comment 12 Petr Jiricka 2007-01-10 14:10:17 UTC
> do we really want to encourage continued use of an old API going forward in
> creating NEW apps on the NEW GF v2?

Why do you think this is about NEW apps? This issue is about J2EE 1.4 apps,
which are mostly existing apps. Why would anyone want to create a NEW app as
J2EE 1.4? When people want JAX-WS, they should choose Java EE 5 (which, BTW, is
the default).

Comment 13 Vince Kraemer 2007-01-10 15:41:35 UTC
I think we need to concentrate on the BUG not the philosophy...  We give the
user the choice to create a J2EE 1.4 web application project in 5.5.1.  The user
has to  take explicit action to decide to NOT use jdk4 source. If the user
chooses J2ee 1.4/jdk4 and then tries to create a web service, JAX-RPC is the
only valid implementation, right?  It is what users expect, right? It looks like
folks are proposing that 5.5.1 should not support j2ee 1.4 if the target server
is GF V2... That isn't a palatable option.
Comment 14 Milan Kuchtiak 2007-01-10 16:16:15 UTC
So from the discussion above: for NB5.5.1/GF V2 we should keep the same
functionality that was in NB55/GF V1.

What are the requirements then (whet GF V2 is a target server) :

- create defaultly JAX-RPC web service for J2EE1.4 project
- create defaultly JAX-WS web service for JAVA EE5 project

The problem is that for GF V1 (in JAVA EE 5 project) the portable artifacts were
created automatically when Tango jars were present. 

Now the only option, as I see, is to let user decide whether the JAX-WS
artifacts should be created or not.
Martin, please suggest some UI and I'll try to implement that.

The question for Martin. Should we allow user to create portable JAX-WS
artifacts even for the configuration J2EE1.4 project - GF V2(with WSIT) ?
Comment 15 Milan Kuchtiak 2007-01-24 14:59:17 UTC
Suggested fix :

- remove wsit tests from the wizard code
- add lib/webservices-rt.jar and webservices-tools.jar to wsimport classpath 
http://web.netbeans.org/source/browse/serverplugins/sun/appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/PlatformImpl.java?r1=1.19&r2=1.20

Code reviewer : Martin Grebac
Comment 16 Milan Kuchtiak 2007-01-24 16:25:43 UTC
Problem in appserverplugin PlatformImpl already fixed (in 5.5.1) :
See the issue 91855.

Now, after security issues are fixed in GlassFish V2, the wsit tests can be
removed from wizards and from particular views (Web project, Ejb project, J2EE
Client Application project).

The resulted behaviour of the wizards will be following :
(Generated services/clients according to the project type)

J2EE1.4 project type:
JAX-RPC services, JAX-RPC clients

Java EE 5 project type:
JAX-WS services, JAX-WS clients
Comment 17 Martin Grebac 2007-02-01 13:48:54 UTC
I'm going to remove wsit checks from trunk, then submit request for removal in
release551, and reassign to Milan if there are other sub-problems left (not
caused by wsit checks in the code).
Comment 18 Martin Grebac 2007-02-01 13:53:05 UTC
Fixed in trunk, I'm gonna create diff to release551 branch.

IDE:-------------------------------------------------
IDE: [2/1/07 2:52 PM] Committing started
Checking in
websvc/jaxrpcsupport/src/org/netbeans/modules/websvc/jaxrpc/client/wizard/WebServiceClientCreator.java;
/cvs/websvc/jaxrpcsupport/src/org/netbeans/modules/websvc/jaxrpc/client/wizard/WebServiceClientCreator.java,v
 <--  WebServiceClientCreator.java
new revision: 1.2; previous revision: 1.1
done
Checking in
websvc/core/src/org/netbeans/modules/websvc/core/dev/wizard/JaxWsServiceCreatorProvider.java;
/cvs/websvc/core/src/org/netbeans/modules/websvc/core/dev/wizard/JaxWsServiceCreatorProvider.java,v
 <--  JaxWsServiceCreatorProvider.java
new revision: 1.2; previous revision: 1.1
done
Checking in
websvc/core/src/org/netbeans/modules/websvc/core/dev/wizard/ProjectInfo.java;
/cvs/websvc/core/src/org/netbeans/modules/websvc/core/dev/wizard/ProjectInfo.java,v
 <--  ProjectInfo.java
new revision: 1.3; previous revision: 1.2
done
Checking in
websvc/core/src/org/netbeans/modules/websvc/core/dev/wizard/JaxWsServiceCreator.java;
/cvs/websvc/core/src/org/netbeans/modules/websvc/core/dev/wizard/JaxWsServiceCreator.java,v
 <--  JaxWsServiceCreator.java
new revision: 1.3; previous revision: 1.2
done
Checking in
websvc/core/src/org/netbeans/modules/websvc/core/dev/wizard/WebServiceFromWSDLPanel.java;
/cvs/websvc/core/src/org/netbeans/modules/websvc/core/dev/wizard/WebServiceFromWSDLPanel.java,v
 <--  WebServiceFromWSDLPanel.java
new revision: 1.3; previous revision: 1.2
done
Checking in websvc/core/src/org/netbeans/modules/websvc/core/JaxWsUtils.java;
/cvs/websvc/core/src/org/netbeans/modules/websvc/core/JaxWsUtils.java,v  <-- 
JaxWsUtils.java
new revision: 1.4; previous revision: 1.3
done
Checking in
websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/WebServiceFromWSDLPanel.java;
/cvs/websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/WebServiceFromWSDLPanel.java,v
 <--  WebServiceFromWSDLPanel.java
new revision: 1.4; previous revision: 1.3
done
Checking in websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/PlatformUtil.java;
/cvs/websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/PlatformUtil.java,v 
<--  PlatformUtil.java
new revision: 1.3; previous revision: 1.2
done
Checking in
websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/WebServiceCreator.java;
/cvs/websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/WebServiceCreator.java,v
 <--  WebServiceCreator.java
new revision: 1.6; previous revision: 1.5
done
Checking in
websvc/jaxrpcsupport/src/org/netbeans/modules/websvc/jaxrpc/dev/wizard/JaxRpcServiceCreatorProvider.java;
/cvs/websvc/jaxrpcsupport/src/org/netbeans/modules/websvc/jaxrpc/dev/wizard/JaxRpcServiceCreatorProvider.java,v
 <--  JaxRpcServiceCreatorProvider.java
new revision: 1.2; previous revision: 1.1
done
Checking in
websvc/core/src/org/netbeans/modules/websvc/core/client/wizard/ClientInfo.java;
/cvs/websvc/core/src/org/netbeans/modules/websvc/core/client/wizard/ClientInfo.java,v
 <--  ClientInfo.java
new revision: 1.33; previous revision: 1.32
done
Checking in
websvc/core/src/org/netbeans/modules/websvc/core/client/wizard/JaxWsClientCreator.java;
/cvs/websvc/core/src/org/netbeans/modules/websvc/core/client/wizard/JaxWsClientCreator.java,v
 <--  JaxWsClientCreator.java
new revision: 1.4; previous revision: 1.3
done
Checking in
serverplugins/sun/appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/PlatformImpl.java;
/cvs/serverplugins/sun/appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/PlatformImpl.java,v
 <--  PlatformImpl.java
new revision: 1.22; previous revision: 1.21
done
Checking in web/project/src/org/netbeans/modules/web/project/ui/WebViews.java;
/cvs/web/project/src/org/netbeans/modules/web/project/ui/WebViews.java,v  <-- 
WebViews.java
new revision: 1.58; previous revision: 1.57
done
Checking in
j2ee/clientproject/src/org/netbeans/modules/j2ee/clientproject/ui/AppClientLogicalViewProvider.java;
/cvs/j2ee/clientproject/src/org/netbeans/modules/j2ee/clientproject/ui/AppClientLogicalViewProvider.java,v
 <--  AppClientLogicalViewProvider.java
new revision: 1.5; previous revision: 1.4
done
Checking in websvc/external/build.xml;
/cvs/websvc/external/build.xml,v  <--  build.xml
new revision: 1.11; previous revision: 1.10
done
IDE: [2/1/07 2:52 PM] Committing finished
Comment 19 Martin Grebac 2007-02-01 17:14:31 UTC
Created attachment 37931 [details]
Diff against release551
Comment 20 Vince Kraemer 2007-02-01 17:54:45 UTC
The changes serverplugins/sun/appsrv81/.../PlatformImpl.java look suspicious.

Did you test this with SJSAS 8.2?  You may be introducing the inverse of issue
90481.
Comment 21 Martin Grebac 2007-02-01 18:00:11 UTC
I don't understand what is suspicious for you. Please elaborate. Thanks.
Have you seen webservices.jar somewhere? This is a file that has been an old
WSIT artifact and it doesn't exist nor is supported anymore.
Comment 22 Lukas Jungmann 2007-02-02 12:01:47 UTC
The fix works fine in trunk (and fixes problem described in this issue). So it
can go into release551 branch.

OTOH it doesn't fix "related" issue 92868. Martine can you please check it and
eventually remove the dependency between these issues?
Thanks.
Comment 23 Milan Kuchtiak 2007-02-05 10:23:35 UTC
The fix looks fine in 6.0 code.
Comment 24 Martin Grebac 2007-02-05 10:39:44 UTC
Fixed in release551 branch:

IDE:-------------------------------------------------
IDE: [2/5/07 11:32 AM] Committing started
Checking in
websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/WebServiceFromWSDLPanel.java;
/cvs/websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/WebServiceFromWSDLPanel.java,v
 <--  WebServiceFromWSDLPanel.java
new revision: 1.1.2.22.14.1; previous revision: 1.1.2.22
done
Checking in websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/PlatformUtil.java;
/cvs/websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/PlatformUtil.java,v 
<--  PlatformUtil.java
new revision: 1.1.2.4.18.1; previous revision: 1.1.2.4
done
Checking in
websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/WebServiceCreator.java;
/cvs/websvc/dev/src/org/netbeans/modules/websvc/dev/wizard/WebServiceCreator.java,v
 <--  WebServiceCreator.java
new revision: 1.1.2.53.6.1; previous revision: 1.1.2.53
done
Checking in
j2ee/clientproject/src/org/netbeans/modules/j2ee/clientproject/ui/AppClientLogicalViewProvider.java;
/cvs/j2ee/clientproject/src/org/netbeans/modules/j2ee/clientproject/ui/AppClientLogicalViewProvider.java,v
 <--  AppClientLogicalViewProvider.java
new revision: 1.1.4.9.20.1; previous revision: 1.1.4.9
done
Checking in
websvc/core/src/org/netbeans/modules/websvc/core/client/wizard/ClientInfo.java;
/cvs/websvc/core/src/org/netbeans/modules/websvc/core/client/wizard/ClientInfo.java,v
 <--  ClientInfo.java
new revision: 1.20.8.3.2.41.10.1; previous revision: 1.20.8.3.2.41
done
Checking in
websvc/core/src/org/netbeans/modules/websvc/core/client/wizard/WebServiceClientCreator.java;
/cvs/websvc/core/src/org/netbeans/modules/websvc/core/client/wizard/Attic/WebServiceClientCreator.java,v
 <--  WebServiceClientCreator.java
new revision: 1.1.2.29.6.1; previous revision: 1.1.2.29
done
Checking in websvc/core/src/org/netbeans/modules/websvc/core/jaxws/JaxWsUtils.java;
/cvs/websvc/core/src/org/netbeans/modules/websvc/core/jaxws/Attic/JaxWsUtils.java,v
 <--  JaxWsUtils.java
new revision: 1.1.2.22.6.2; previous revision: 1.1.2.22.6.1
done
Checking in
serverplugins/sun/appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/PlatformImpl.java;
/cvs/serverplugins/sun/appsrv81/src/org/netbeans/modules/j2ee/sun/ide/j2ee/PlatformImpl.java,v
 <--  PlatformImpl.java
new revision: 1.3.8.7.2.24.14.3; previous revision: 1.3.8.7.2.24.14.2
done
Checking in web/project/src/org/netbeans/modules/web/project/ui/WebViews.java;
/cvs/web/project/src/org/netbeans/modules/web/project/ui/WebViews.java,v  <-- 
WebViews.java
new revision: 1.46.2.4.2.23.6.1; previous revision: 1.46.2.4.2.23
done
IDE: [2/5/07 11:33 AM] Committing finished
Comment 25 Jaroslav Pospisil 2007-02-14 13:58:06 UTC
Verified in 200702140600