Return-Path: Delivered-To: apmail-ws-axis-dev-archive@www.apache.org Received: (qmail 54651 invoked from network); 23 Feb 2009 11:09:36 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 23 Feb 2009 11:09:36 -0000 Received: (qmail 44735 invoked by uid 500); 23 Feb 2009 11:09:33 -0000 Delivered-To: apmail-ws-axis-dev-archive@ws.apache.org Received: (qmail 44686 invoked by uid 500); 23 Feb 2009 11:09:32 -0000 Mailing-List: contact axis-dev-help@ws.apache.org; run by ezmlm Precedence: bulk Reply-To: axis-dev@ws.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list axis-dev@ws.apache.org Received: (qmail 44677 invoked by uid 99); 23 Feb 2009 11:09:32 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 23 Feb 2009 03:09:32 -0800 X-ASF-Spam-Status: No, hits=-1998.5 required=10.0 tests=ALL_TRUSTED,WEIRD_PORT X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 23 Feb 2009 11:09:23 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 00BA5234C4A7 for ; Mon, 23 Feb 2009 03:09:02 -0800 (PST) Message-ID: <33660403.1235387342002.JavaMail.jira@brutus> Date: Mon, 23 Feb 2009 03:09:02 -0800 (PST) From: "Franck Michel (JIRA)" To: axis-dev@ws.apache.org Subject: [jira] Updated: (AXIS2-4247) JAX-WS API fails to build an endpoint reference (IllegalStateException) when service is published with Endpoint.publish() In-Reply-To: <1485047256.1235386862733.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/AXIS2-4247?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Franck Michel updated AXIS2-4247: --------------------------------- Attachment: Axis2Test.java > JAX-WS API fails to build an endpoint reference (IllegalStateException) when service is published with Endpoint.publish() > ------------------------------------------------------------------------------------------------------------------------- > > Key: AXIS2-4247 > URL: https://issues.apache.org/jira/browse/AXIS2-4247 > Project: Axis 2.0 (Axis2) > Issue Type: Bug > Components: jaxws > Affects Versions: nightly > Environment: JDK 1.6.0_06, WinXP > Reporter: Franck Michel > Attachments: Axis2Test.java, LaunchA2xis2Test.java > > > Hi, I'm facing a trouble using the Enpoint.publish() JAXWS API. I've checked several issues that may be related, with no success until now : > https://issues.apache.org/jira/browse/AXIS2-3116?page=com.atlassian.jira.plugin.ext.subversion:subversion-commits-tabpanel > https://wso2.org/jira/browse/CARBON-738 > I'm using the last nightly build as some issues were fixed on this kind of thing recently. > I publish a very basic WS Endpoint.publish(String url) API: the service seems to be published (isPublished() returns true), but it fails to return an endpoint reference. My code does this (the code of the web service is at the end of this post): > Endpoint endPoint = Endpoint.create(new Axis2Test()); > endPoint.publish("http://localhost:8081/services/Test"); > logger.debug("isPublished: " + endPoint.isPublished()); > logger.debug("getProperties: " + endPoint.getProperties()); > logger.debug("getMetadata: " + endPoint.getMetadata()); > logger.debug("getEndpointReference: " + endPoint.getEndpointReference()); > This fails on endPoint.getEndpointReference(), an returns: > 2009-02-23 11:28:37,242 [main] DEBUG fr.anr.techlog.neurolog.server.LaunchStandaloneWebServices:18 - isPublished: true > 2009-02-23 11:28:37,242 [main] DEBUG fr.anr.techlog.neurolog.server.LaunchStandaloneWebServices:19 - getProperties: null > 2009-02-23 11:28:37,242 [main] DEBUG fr.anr.techlog.neurolog.server.LaunchStandaloneWebServices:20 - getMetadata: null > 2009-02-23 11:28:37,492 [main] FATAL fr.anr.techlog.neurolog.server.LaunchStandaloneWebServices:24 - Unable to create server > java.lang.IllegalStateException: Unable to locate a deployed service that maps to the requested endpoint, Service: {http://mypackage/}Axis2TestService, Port: {http://mypackage/}Axis2TestPort > at org.apache.axis2.jaxws.addressing.factory.impl.Axis2EndpointReferenceFactoryImpl.createEndpointReference(Axis2EndpointReferenceFactoryImpl.java:66) > at org.apache.axis2.jaxws.addressing.factory.impl.Axis2EndpointReferenceFactoryImpl.createEndpointReference(Axis2EndpointReferenceFactoryImpl.java:97) > at org.apache.axis2.jaxws.addressing.util.EndpointReferenceUtils.createAxis2EndpointReference(EndpointReferenceUtils.java:133) > at org.apache.axis2.jaxws.server.endpoint.EndpointImpl.getEndpointReference(EndpointImpl.java:244) > at org.apache.axis2.jaxws.server.endpoint.EndpointImpl.getEndpointReference(EndpointImpl.java:261) > at mypackage.LaunchA2xis2Test.main(LaunchA2xis2Test.java:21) > Also, accessing the service using Firefox returns this : > 2009-02-23 11:52:46,184 [HttpConnection-8081-2] ERROR org.apache.axis2.engine.AxisEngine:212 - The service cannot be found for the endpoint reference (EPR) /services/Test?wsdl > org.apache.axis2.AxisFault: The service cannot be found for the endpoint reference (EPR) /services/Test?wsdl > at org.apache.axis2.engine.DispatchPhase.checkPostConditions(DispatchPhase.java:65) > at org.apache.axis2.engine.Phase.invoke(Phase.java:333) > at org.apache.axis2.engine.AxisEngine.invoke(AxisEngine.java:264) > at org.apache.axis2.engine.AxisEngine.receive(AxisEngine.java:163) > at org.apache.axis2.transport.http.util.RESTUtil.invokeAxisEngine(RESTUtil.java:136) > at org.apache.axis2.transport.http.util.RESTUtil.processURLRequest(RESTUtil.java:130) > at org.apache.axis2.transport.http.HTTPWorker.service(HTTPWorker.java:257) > at org.apache.axis2.transport.http.server.AxisHttpService.doService(AxisHttpService.java:281) > at org.apache.axis2.transport.http.server.AxisHttpService.handleRequest(AxisHttpService.java:187) > at org.apache.axis2.transport.http.server.HttpServiceProcessor.run(HttpServiceProcessor.java:82) > at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1061) > at edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:575) > at java.lang.Thread.run(Thread.java:619) > In addition, a quite curious behaviour is this: when I get this URL, http://localhost:8081/services/Axis2TestService.Axis2TestPort, I get a proper service page with a correct list of available operations. However the link to the wsdl (http://localhost:8081/services/Axis2TestService.Axis2TestPort?wsdl) returns another error : > 2009-02-23 11:55:31,728 [HttpConnection-8081-4] WARN org.apache.axis2.description.AxisService:1003 - Unable to generate EPR for the transport : http > My web service code is the most simple that could be: > import javax.jws.WebService; > @WebService > public class Axis2Test > { > public Axis2Test() {} > public int getNumber() { > return 0; > } > } -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.