You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Hadrian Zbarcea (JIRA)" <ji...@apache.org> on 2011/09/01 22:47:10 UTC

[jira] [Created] (CAMEL-4405) Invalid URIs used by camel-cxf

Invalid URIs used by camel-cxf
------------------------------

                 Key: CAMEL-4405
                 URL: https://issues.apache.org/jira/browse/CAMEL-4405
             Project: Camel
          Issue Type: Bug
          Components: camel-cxf
    Affects Versions: 2.8.0
            Reporter: Hadrian Zbarcea
            Assignee: Hadrian Zbarcea
            Priority: Critical
             Fix For: 2.9.0


This is a nasty one.

We currently support URIs of the following form in camel-cxf:
{code}
"cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&serviceName={http://camel.apache.org/wsdl-first}PersonService&portName={http://camel.apache.org/wsdl-first}soap"
{code}

As curly brackets are not valid, URIs like above are invalid. Unfortunately I suspect there are too many users who use this format now to just fix it so we need to deprecate this format, find a workaround and a solution.

The solution I am proposing is to use another parameter: targetNamespace to replace the value between the curlies for the serviceName. The portName should not be a QName actually either. As such, the example above would become:

{code}
"cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&targetNamespace=http://camel.apache.org/wsdl-first&serviceName=PersonService&portName=soap"
{code}

I will look for a workaround too, to not break existing code too much.


--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-4405) Invalid URIs used by camel-cxf

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-4405?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13095785#comment-13095785 ] 

Claus Ibsen commented on CAMEL-4405:
------------------------------------

People have been using this for years with no general problem at all. Why suddenly all the fuzz and marking it as critical and whatnot?

> Invalid URIs used by camel-cxf
> ------------------------------
>
>                 Key: CAMEL-4405
>                 URL: https://issues.apache.org/jira/browse/CAMEL-4405
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-cxf
>    Affects Versions: 2.8.0
>            Reporter: Hadrian Zbarcea
>            Assignee: Hadrian Zbarcea
>            Priority: Critical
>             Fix For: 2.9.0
>
>
> This is a nasty one.
> We currently support URIs of the following form in camel-cxf:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&serviceName={http://camel.apache.org/wsdl-first}PersonService&portName={http://camel.apache.org/wsdl-first}soap"
> {code}
> As curly brackets are not valid, URIs like above are invalid. Unfortunately I suspect there are too many users who use this format now to just fix it so we need to deprecate this format, find a workaround and a solution.
> The solution I am proposing is to use another parameter: targetNamespace to replace the value between the curlies for the serviceName. The portName should not be a QName actually either. As such, the example above would become:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&targetNamespace=http://camel.apache.org/wsdl-first&serviceName=PersonService&portName=soap"
> {code}
> I will look for a workaround too, to not break existing code too much.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Issue Comment Edited] (CAMEL-4405) Invalid URIs used by camel-cxf

Posted by "Willem Jiang (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-4405?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13095710#comment-13095710 ] 

Willem Jiang edited comment on CAMEL-4405 at 9/2/11 1:41 AM:
-------------------------------------------------------------


The portName and serviceName may share difference namespace, we may need add options for this issue.
In CxfEndpoint spring configuration we use the endpointName for the portName, we also unify the options definition.
I suggest we use the endpointName for the portName, as the CXF is using the endpointName which is also used in WSDL2 definition.

In CXFSpringEndpoint ,there are some method for set and get these options.
 like serviceNamespace, serviceLocalName, endpointNamespace, endpointLocalName
If we move these method into CXFEndpoint, camel-cxf URI can be a good URI citizen. 

If we don't support the of serviceName and portName option for the camel-cxf URI, it will hurt the user.
So I suggest to deprecate them in Camel 2.9 and remove the support of these option in URI in Camel 3.0.


      was (Author: njiang):
    "{" and "}" are not URI safe character, we did some work in Camel when it parsers endpoint URI to support it.
If you are passing the URI which is encoded to camel, you may face that kind of trouble. 
As most user don't do it, we don't get this kind of alarm before.

Back to the issue, the portName and serviceName may share difference namespace, we may need add options for this issue.
In CxfEndpoint spring configuration we use the endpointName for the portName, we also unify the options definition.
I suggest we use the endpointName for the portName, as the CXF is using the endpointName which is also used in WSDL2 definition.

In CXFSpringEndpoint ,there are some method for set and get these options.
 like serviceNamespace, serviceLocalName, endpointNamespace, endpointLocalName
If we move these method into CXFEndpoint, camel-cxf URI can be a good URI citizen. 

If we don't support the of serviceName and portName option for the camel-cxf URI, it will hurt the user.
So I suggest to deprecate them in Camel 2.9 and remove the support of these option in URI in Camel 3.0.

  
> Invalid URIs used by camel-cxf
> ------------------------------
>
>                 Key: CAMEL-4405
>                 URL: https://issues.apache.org/jira/browse/CAMEL-4405
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-cxf
>    Affects Versions: 2.8.0
>            Reporter: Hadrian Zbarcea
>            Assignee: Hadrian Zbarcea
>            Priority: Critical
>             Fix For: 2.9.0
>
>
> This is a nasty one.
> We currently support URIs of the following form in camel-cxf:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&serviceName={http://camel.apache.org/wsdl-first}PersonService&portName={http://camel.apache.org/wsdl-first}soap"
> {code}
> As curly brackets are not valid, URIs like above are invalid. Unfortunately I suspect there are too many users who use this format now to just fix it so we need to deprecate this format, find a workaround and a solution.
> The solution I am proposing is to use another parameter: targetNamespace to replace the value between the curlies for the serviceName. The portName should not be a QName actually either. As such, the example above would become:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&targetNamespace=http://camel.apache.org/wsdl-first&serviceName=PersonService&portName=soap"
> {code}
> I will look for a workaround too, to not break existing code too much.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CAMEL-4405) Invalid URIs used by camel-cxf

Posted by "Claus Ibsen (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAMEL-4405?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Claus Ibsen updated CAMEL-4405:
-------------------------------

    Priority: Major  (was: Critical)
    
> Invalid URIs used by camel-cxf
> ------------------------------
>
>                 Key: CAMEL-4405
>                 URL: https://issues.apache.org/jira/browse/CAMEL-4405
>             Project: Camel
>          Issue Type: Sub-task
>          Components: camel-cxf
>    Affects Versions: 2.8.0
>            Reporter: Hadrian Zbarcea
>            Assignee: Hadrian Zbarcea
>             Fix For: 2.9.0
>
>
> This is a nasty one.
> We currently support URIs of the following form in camel-cxf:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&serviceName={http://camel.apache.org/wsdl-first}PersonService&portName={http://camel.apache.org/wsdl-first}soap"
> {code}
> As curly brackets are not valid, URIs like above are invalid. Unfortunately I suspect there are too many users who use this format now to just fix it so we need to deprecate this format, find a workaround and a solution.
> The solution I am proposing is to use another parameter: targetNamespace to replace the value between the curlies for the serviceName. The portName should not be a QName actually either. As such, the example above would become:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&targetNamespace=http://camel.apache.org/wsdl-first&serviceName=PersonService&portName=soap"
> {code}
> I will look for a workaround too, to not break existing code too much.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-4405) Invalid URIs used by camel-cxf

Posted by "Hadrian Zbarcea (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-4405?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13095721#comment-13095721 ] 

Hadrian Zbarcea commented on CAMEL-4405:
----------------------------------------

@Willem, as per the [wsdl spec|http://www.w3.org/TR/wsdl#_ports], the port @name is an 'nmtoken' not a 'qname'. Being part of a service it shares its namespace. Does CXF interpret this differently?

Even if that were the case, we'd define two parameters then, something like serviceNamespace, and endpointNamespace, as you suggest, so it's not a biggie.

I agree we need to support the current way, flawed as it is until 3.0 and I agree with the suggestion to fix and deprecate. I will not comment on the reason why we didn't catch it until now, I am as guilty as anyone.

We can expect URIs to be UTF-8 encoded. Supporting other encodings would be a feature we could consider for the future, but I am not too worried about that now. If a URI not properly encoded is passed now, it's a toss up. After looking into the details of the code I can give examples that are invalid, yet work, and I can give examples that fail miserably (without even an clear explanation of what went wrong). It's fixable though in a few ways and I think I have a solution.


> Invalid URIs used by camel-cxf
> ------------------------------
>
>                 Key: CAMEL-4405
>                 URL: https://issues.apache.org/jira/browse/CAMEL-4405
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-cxf
>    Affects Versions: 2.8.0
>            Reporter: Hadrian Zbarcea
>            Assignee: Hadrian Zbarcea
>            Priority: Critical
>             Fix For: 2.9.0
>
>
> This is a nasty one.
> We currently support URIs of the following form in camel-cxf:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&serviceName={http://camel.apache.org/wsdl-first}PersonService&portName={http://camel.apache.org/wsdl-first}soap"
> {code}
> As curly brackets are not valid, URIs like above are invalid. Unfortunately I suspect there are too many users who use this format now to just fix it so we need to deprecate this format, find a workaround and a solution.
> The solution I am proposing is to use another parameter: targetNamespace to replace the value between the curlies for the serviceName. The portName should not be a QName actually either. As such, the example above would become:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&targetNamespace=http://camel.apache.org/wsdl-first&serviceName=PersonService&portName=soap"
> {code}
> I will look for a workaround too, to not break existing code too much.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-4405) Invalid URIs used by camel-cxf

Posted by "Willem Jiang (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-4405?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13095710#comment-13095710 ] 

Willem Jiang commented on CAMEL-4405:
-------------------------------------

"{" and "}" are not URI safe character, we did some work in Camel when it parsers endpoint URI to support it.
If you are passing the URI which is encoded to camel, you may face that kind of trouble. 
As most user don't do it, we don't get this kind of alarm before.

Back to the issue, the portName and serviceName may share difference namespace, we may need add options for this issue.
In CxfEndpoint spring configuration we use the endpointName for the portName, we also unify the options definition.
I suggest we use the endpointName for the portName, as the CXF is using the endpointName which is also used in WSDL2 definition.

In CXFSpringEndpoint ,there are some method for set and get these options.
 like serviceNamespace, serviceLocalName, endpointNamespace, endpointLocalName
If we move these method into CXFEndpoint, camel-cxf URI can be a good URI citizen. 

If we don't support the of serviceName and portName option for the camel-cxf URI, it will hurt the user.
So I suggest to deprecate them in Camel 2.9 and remove the support of these option in URI in Camel 3.0.


> Invalid URIs used by camel-cxf
> ------------------------------
>
>                 Key: CAMEL-4405
>                 URL: https://issues.apache.org/jira/browse/CAMEL-4405
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-cxf
>    Affects Versions: 2.8.0
>            Reporter: Hadrian Zbarcea
>            Assignee: Hadrian Zbarcea
>            Priority: Critical
>             Fix For: 2.9.0
>
>
> This is a nasty one.
> We currently support URIs of the following form in camel-cxf:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&serviceName={http://camel.apache.org/wsdl-first}PersonService&portName={http://camel.apache.org/wsdl-first}soap"
> {code}
> As curly brackets are not valid, URIs like above are invalid. Unfortunately I suspect there are too many users who use this format now to just fix it so we need to deprecate this format, find a workaround and a solution.
> The solution I am proposing is to use another parameter: targetNamespace to replace the value between the curlies for the serviceName. The portName should not be a QName actually either. As such, the example above would become:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&targetNamespace=http://camel.apache.org/wsdl-first&serviceName=PersonService&portName=soap"
> {code}
> I will look for a workaround too, to not break existing code too much.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CAMEL-4405) Invalid URIs used by camel-cxf

Posted by "Hadrian Zbarcea (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CAMEL-4405?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Hadrian Zbarcea updated CAMEL-4405:
-----------------------------------

    Issue Type: Sub-task  (was: Bug)
        Parent: CAMEL-4425

> Invalid URIs used by camel-cxf
> ------------------------------
>
>                 Key: CAMEL-4405
>                 URL: https://issues.apache.org/jira/browse/CAMEL-4405
>             Project: Camel
>          Issue Type: Sub-task
>          Components: camel-cxf
>    Affects Versions: 2.8.0
>            Reporter: Hadrian Zbarcea
>            Assignee: Hadrian Zbarcea
>            Priority: Critical
>             Fix For: 2.9.0
>
>
> This is a nasty one.
> We currently support URIs of the following form in camel-cxf:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&serviceName={http://camel.apache.org/wsdl-first}PersonService&portName={http://camel.apache.org/wsdl-first}soap"
> {code}
> As curly brackets are not valid, URIs like above are invalid. Unfortunately I suspect there are too many users who use this format now to just fix it so we need to deprecate this format, find a workaround and a solution.
> The solution I am proposing is to use another parameter: targetNamespace to replace the value between the curlies for the serviceName. The portName should not be a QName actually either. As such, the example above would become:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&targetNamespace=http://camel.apache.org/wsdl-first&serviceName=PersonService&portName=soap"
> {code}
> I will look for a workaround too, to not break existing code too much.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CAMEL-4405) Invalid URIs used by camel-cxf

Posted by "Willem Jiang (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CAMEL-4405?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13095712#comment-13095712 ] 

Willem Jiang commented on CAMEL-4405:
-------------------------------------

"{" and "}" are not URI safe character, we did some work in Camel when it parsers endpoint URI to support it.
If you are passing the URI which is encoded to camel, you may face that kind of trouble. 
As most user don't do it, we don't get this kind of alarm before.
There is a question just comes into my mind, what if the user just pass a URI which is not encoded with UTF-8, or it is not be encoded.


> Invalid URIs used by camel-cxf
> ------------------------------
>
>                 Key: CAMEL-4405
>                 URL: https://issues.apache.org/jira/browse/CAMEL-4405
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-cxf
>    Affects Versions: 2.8.0
>            Reporter: Hadrian Zbarcea
>            Assignee: Hadrian Zbarcea
>            Priority: Critical
>             Fix For: 2.9.0
>
>
> This is a nasty one.
> We currently support URIs of the following form in camel-cxf:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&serviceName={http://camel.apache.org/wsdl-first}PersonService&portName={http://camel.apache.org/wsdl-first}soap"
> {code}
> As curly brackets are not valid, URIs like above are invalid. Unfortunately I suspect there are too many users who use this format now to just fix it so we need to deprecate this format, find a workaround and a solution.
> The solution I am proposing is to use another parameter: targetNamespace to replace the value between the curlies for the serviceName. The portName should not be a QName actually either. As such, the example above would become:
> {code}
> "cxf://http://localhost:9000/CxfEndpointTest/helloworld?wsdlURL=classpath:person.wsdl&targetNamespace=http://camel.apache.org/wsdl-first&serviceName=PersonService&portName=soap"
> {code}
> I will look for a workaround too, to not break existing code too much.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira