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 86228 - cannot switch target server with webservice client.
Summary: cannot switch target server with webservice client.
Status: VERIFIED WONTFIX
Alias: None
Product: webservices
Classification: Unclassified
Component: Code (show other bugs)
Version: 5.x
Hardware: All All
: P1 blocker (vote)
Assignee: Milan Kuchtiak
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-09-29 22:23 UTC by _ hlu
Modified: 2006-10-02 16:45 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ hlu 2006-09-29 22:23:57 UTC
I have created two ee5 based enterprice apps using ide enterprise pack 5.5; one
is for webservice server and one for webservice client. I deployed these two
apps to remote application server and everything worked fine. When I tried to
deploy them to local server, even though I could swith the target server to
local host, the webservice client still used the wsdl file in the remote system.
Comment 1 Petr Jiricka 2006-10-01 20:33:05 UTC
I think this is intentional, do you agree, Milan?
Comment 2 Milan Kuchtiak 2006-10-02 09:15:43 UTC
Yes, the client isn't bound to a specific project, but to a specific url (of
wsdl file). 
See the nbproject/jax-ws.xml <client><wsdl-url>

If target server is changed in web service project, this isn't reflected in the
client. 
One workaround is to change the <wsdl-url> element in jax-ws.xml and refresh the
client.

Another, more elegant solution is to use Web Service injection:
You can simply switch the host name in @WebServiceRef annotation (e.g. in
servlet that contains the client code).

For example, change the folowing line :
@WebServiceRef(wsdlLocation =
"http://remote-server-host.sun.com:8080/fromwsdl/AService?wsdl")
to
@WebServiceRef(wsdlLocation = "http://localhost:8080/fromwsdl/AService?wsdl")
Comment 3 Lukas Jungmann 2006-10-02 16:45:25 UTC
v.