Return-Path: X-Original-To: apmail-cxf-issues-archive@www.apache.org Delivered-To: apmail-cxf-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 02C7CD204 for ; Tue, 23 Oct 2012 14:27:16 +0000 (UTC) Received: (qmail 78943 invoked by uid 500); 23 Oct 2012 14:27:15 -0000 Delivered-To: apmail-cxf-issues-archive@cxf.apache.org Received: (qmail 78051 invoked by uid 500); 23 Oct 2012 14:27:14 -0000 Mailing-List: contact issues-help@cxf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cxf.apache.org Delivered-To: mailing list issues@cxf.apache.org Received: (qmail 77992 invoked by uid 99); 23 Oct 2012 14:27:12 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 23 Oct 2012 14:27:12 +0000 Date: Tue, 23 Oct 2012 14:27:12 +0000 (UTC) From: "Wojtek Malinowski (JIRA)" To: issues@cxf.apache.org Message-ID: <113486856.16006.1351002432729.JavaMail.jiratomcat@arcas> In-Reply-To: <600116585.102531.1348147031473.JavaMail.jiratomcat@arcas> Subject: [jira] [Commented] (CXF-4513) First request to a webservice overrides jaxws:endpoint address parameter. MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CXF-4513?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13482355#comment-13482355 ] Wojtek Malinowski commented on CXF-4513: ---------------------------------------- Hi, actually, the option "disable-address-updates = true" looks exactly how I expected this to work at the beginning (the address is always relative but is also presented with as the full path taken from HTTP/SOAP request). I just didn't know that I can do it this way. Thank you very much for your explanation! > First request to a webservice overrides jaxws:endpoint address parameter. > ------------------------------------------------------------------------- > > Key: CXF-4513 > URL: https://issues.apache.org/jira/browse/CXF-4513 > Project: CXF > Issue Type: Bug > Affects Versions: 2.6.2 > Environment: windows xp/linux debian, tomcat 6.0.29/6.0.35, java 1.6.22 > Reporter: Wojtek Malinowski > > I have prepared some webservice, which has an endpoint configured as follows: > > Having deployed my webservice using CXF 2.6.2 to the tomcat server (6.0.29) locally (but the same situation is on production systems), I'm going into http://localhost:8080/MyService/services servlet and there I'm getting such info: > {code} > publishedEndpointUrl: null > address: /AuthorizationWebService > Endpoint address: http://localhost:8080/MyService/services/AuthorizationWebService > WSDL : {http://test/authorization}AuthorizationService > Target namespace: http://test/authorization > {code} > This is non-standard, because I modified FormattedServiceListWrite to have publishedEndpointUrl and address on the screen: > {code} > writer.write("publishedEndpointUrl: " + "" > + sd.getEndpointInfo().getProperty("publishedEndpointUrl") + ""); > writer.write("
address: " + "" > + sd.getEndpointInfo().getAddress() + ""); > {code} > This is a correct situation, the endpoint address is taken from my request. > But after I called some function from this webservice (and a requested path contains localhost), the returned info changes to: > {code} > publishedEndpointUrl: null > address: http://localhost:8080/MyService/services/AuthorizationWebService > Endpoint address: http://localhost:8080/MyService/services/AuthorizationWebService > WSDL : {http://test/authorization}AuthorizationService > Target namespace: http://test/authorization > {code} > This is worse, because when I try to call this servlet using http://127.0.0.1:8080/MyService/services I will still get the reference with localhost:8080. The next request to this webservice (calling another function) using address 127.0.0.1 does not change the address. But if I called my function for the first after restarting the tomcat using 127.0.0.1 then it would like this: > {code} > publishedEndpointUrl: null > address: http://127.0.0.1:8080/MyService/services/AuthorizationWebService > Endpoint address: http://127.0.0.1:8080/MyService/services/AuthorizationWebService > WSDL : {http://test/authorization}AuthorizationService > Target namespace: http://test/authorization > {code} > To sum up, the address parameter is changed from /AuthorizationWebService to REQUEST_PATH/AuthorizationWebService during the first request to the webservice. This results in incorrect paths showed by the cxf servlet, when webservice is available (and requested by users) through more than one address. > I think the correct behaviour would be that the address parameter would never change, so when I request the servlet listing webservice the "basePath" parameter would still be used to determine the full path despite user requests in a meantime (and would be the same for all webservice as it is before the first request). > Tested on CXF 2.6.2 using windows xp or linux debian, java 1.6.22 and tomcat 6.0.29 (linux) or 6.0.35 (windows). -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira