« Return to Thread: "loan processing" problem: Unsupported endpoint address

Re: "loan processing" problem: Unsupported endpoint address

by jsexton0 :: Rate this Message:

Reply to Author | View in Thread

I have this same problem.  I need to call a web service from inside a Java class that is in a "Web Application" project along with a servlet.  I add this project together with an EJB project into an Enterprise Application project and deploy.

The web service I want to call has it's WSDL in a BPEL project deployed on the same server, in a SA.  I construct the web service client in the web application project and added it to the Java class with no trouble.  But it fails at runtime with "javax.xml.ws.WebServiceException: Unsupported endpoint address".

Couple of observations...

1. When I right click in my Java code, in the Web Application project, and select Web Service Client Resources > Call Web Service Operation, I can only pick WSDLs from EJB projects, no BPEL projects are listed.

2. I found all the instances (three) of the WSDL in question that Netbeans placed/copied under my web application project, from the BPEL project, and edited them to include the actual port instead of ${HttpDefaultPort}.  This did not change the error in any way.

Product Version: NetBeans IDE 6.1 (Build 200805300101)
Java: 1.6.0; Java HotSpot(TM) Client VM 1.6.0-b105
System: Windows XP version 5.1 running on x86; Cp1252; en_US (nb)
Userdir: E:\openesb\.netbeans\openesb

Bing Li-2 wrote:
Hi,
I have figured out how to fix the problem.
1. After we create the web client project (create web service client from a local wsdl file: select LoanRequestor.wsdl), we then do the following (in jsp or in servlet):
Web Service Client Resources > Call Web Service Operation (LoanRequestor.wsdl will be copied to this client project).
2. We have to modify the wsdl file: WEB-INF/wsdl/client/.../LoanRequestor.wsdl.
Change ${HttpDefaultPort} to the specfic port number (9080) in this line:
 <soap:address location="http://localhost:${HttpDefaultPort}/LoanRequestorService/LoanRequestorPort"/>
I in fact generate the client operation in servlet, the annotation @WebServiceRef(wsdlLocation = "WEB-INF/wsdl/client/.... is created, so that we know where to find LoanRequestor.wsdl.
3. run the client.

${HttpDefaultPort} works well in composite application test, but not in web client case.  I am not sure it is a bug or not.  ${HttpDefaultPort} appearantly works in most cases, only two complaints found.
 
Thanks,
Bing (forest86)

--- On Thu, 8/7/08, Bing Li <forest8693@yahoo.com> wrote:

From: Bing Li <forest8693@yahoo.com>
Subject: [entpack] "loan processing" problem: Unsupported endpoint address
To: nbentpack@netbeans.org
Date: Thursday, August 7, 2008, 1:33 PM







Hello all,
 
I found the message below about the "Loan processing" example problem posted in June in Developer Forums of SDN but not answered.  I have the same problem. In my case:
Application server: glassfish-v2ur2

Product Version: NetBeans IDE Dev (Build 200807040101)  (6.5m1)
Java: 1.5.0_14; Java HotSpot(TM) Client VM 1.5.0_14-b03
System: Windows XP version 5.1 running on x86; Cp1252; en_US (nb)
 
Error :
javax.xml.ws.WebServiceException: Unsupported endpoint address:
        at com.sun.xml.ws.api.pipe.TransportTubeFactory.create(TransportTubeFactory.java:144)
        at com.sun.xml.ws.transport.DeferredTransportPipe.processRequest(DeferredTransportPipe.java:112)
        at com.sun.xml.ws.api.pipe.Fiber.__doRun(Fiber.java:595)
...............
 
I need your help.
Thanks in advance,
 
forest86
 
 
=================================
Fab22
Posts:1
Registered: 6/8/08  Call JBI service from web application   
Jun 8, 2008 4:49 PM
 
Hi,
I have just installed the lastest Netbeans 6.1 bundle and I am trying to run the "loan processing" tutorial.
So far, the following steps have been very easy:
- Deploying LoanProcessor EJB: ok
- Creating BPEL + Running LoanRequestorCompositeApplication: ok
- Unit Testing composite application: ok
Then instead of providing my input data through xml, I have tried to input user data from a web application.
Similar examples have been described on the web, but I cannot get the webservice call to work.
Problem encountered: "unsupported endpoint address".
I can provide my projects for debugging purpose.
Can anybody provide examples on this topic.
The following code is used in the loanClient.jsp file:
org.netbeans.j2ee.wsdl.loanrequestor.LoanRequestorService service = new org.netbeans.j2ee.wsdl.loanrequestor.LoanRequestorService();
org.netbeans.j2ee.wsdl.loanrequestor.LoanRequestorPortType port = service..getLoanRequestorPort();
// TODO initialize WS operation arguments here
org.netbeans.xml.schema.loanrequestor.ProcessApplicType requestLoanMessage = new org.netbeans.xml.schema.loanrequestor.ProcessApplicType();
requestLoanMessage.setSocialSecurityNumber(request.getParameter("ssn"));
requestLoanMessage.setApplicantName(request.getParameter("name"));
requestLoanMessage.setApplicantAddress(request.getParameter("address"));
requestLoanMessage.setApplicantEmailAddress(request.getParameter("email"));
requestLoanMessage.setApplicantAge(Integer.parseInt(request.getParameter("age")));
requestLoanMessage.setApplicantGender(request.getParameter("gender"));
requestLoanMessage.setAnnualSalary(Double.parseDouble(request.getParameter("salary")));
requestLoanMessage.setAmountRequested(Double.parseDouble(request.getParameter("loanamount")));
 
//TODO process result here
org.netbeans.xml.schema.loanrequestor.ProcessApplicRespType result = port..loanRequestorOperation(requestLoanMessage);
out.println("Result = " + result.getReturn());
 
Thanks in advance



 « Return to Thread: "loan processing" problem: Unsupported endpoint address