You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Chris Moesel (JIRA)" <ji...@apache.org> on 2007/03/30 16:58:25 UTC

[jira] Created: (CXF-507) Spring Config of portName and serviceName does not work

Spring Config of portName and serviceName does not work
-------------------------------------------------------

                 Key: CXF-507
                 URL: https://issues.apache.org/jira/browse/CXF-507
             Project: CXF
          Issue Type: Bug
          Components: Configuration, JAX-WS Runtime
    Affects Versions: 2.0-RC
         Environment: Using 2.0-RC SNAPSHOT
            Reporter: Chris Moesel


The documentation at the following page indicates that a portName and serviceName can be specified as attributes in <jaxws:endpoint> in the spring config file:
http://cwiki.apache.org/CXF20DOC/jax-ws-configuration.html

There are two issues:

1)  If the portName and serviceName are specified as recommended in the documentation, Spring does not properly parse the config file, due to the following exception:
org.xml.sax.SAXParseException: cvc-datatype-valid.1.2.1: '{http://mycompany.com/products/webservice}MyServicePort' is not a valid value for 'QName'.
I was able to get it to parse by adding the following to the root beans element:
xmlns:mws="http://mycompany.com/products/webservice"
And then specifying the portName like so: "mws:MyServicePort"

2)  Once you've gotten past #1 above,  you get the following error:
org.springframework.beans.NotWritablePropertyException: Invalid property 'portName' of bean class [org.apache.cxf.jaxws.spring.EndpointFactoryBean]: Bean property 'portName' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
Looking at the source code, it appears there are no setters for portName or serviceName:
http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/spring/EndpointFactoryBean.java?view=markup


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (CXF-507) Spring Config of portName and serviceName does not work

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

Dan Diephouse reassigned CXF-507:
---------------------------------

    Assignee: Dan Diephouse

> Spring Config of portName and serviceName does not work
> -------------------------------------------------------
>
>                 Key: CXF-507
>                 URL: https://issues.apache.org/jira/browse/CXF-507
>             Project: CXF
>          Issue Type: Bug
>          Components: Configuration, JAX-WS Runtime
>    Affects Versions: 2.0-RC
>         Environment: Using 2.0-RC SNAPSHOT
>            Reporter: Chris Moesel
>         Assigned To: Dan Diephouse
>
> The documentation at the following page indicates that a portName and serviceName can be specified as attributes in <jaxws:endpoint> in the spring config file:
> http://cwiki.apache.org/CXF20DOC/jax-ws-configuration.html
> There are two issues:
> 1)  If the portName and serviceName are specified as recommended in the documentation, Spring does not properly parse the config file, due to the following exception:
> org.xml.sax.SAXParseException: cvc-datatype-valid.1.2.1: '{http://mycompany.com/products/webservice}MyServicePort' is not a valid value for 'QName'.
> I was able to get it to parse by adding the following to the root beans element:
> xmlns:mws="http://mycompany.com/products/webservice"
> And then specifying the portName like so: "mws:MyServicePort"
> 2)  Once you've gotten past #1 above,  you get the following error:
> org.springframework.beans.NotWritablePropertyException: Invalid property 'portName' of bean class [org.apache.cxf.jaxws.spring.EndpointFactoryBean]: Bean property 'portName' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
> Looking at the source code, it appears there are no setters for portName or serviceName:
> http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/spring/EndpointFactoryBean.java?view=markup

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CXF-507) Spring Config of portName and serviceName does not work

Posted by "Glen Mazza (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12572754#action_12572754 ] 

Glen Mazza commented on CXF-507:
--------------------------------

Hmm, I thought Willem fixed this to allow CXF to use portName instead of endpointName.  If not, I wonder if it would be better if the Spring config were expanded to support portName while keeping endpointName supported, but deprecated and undocumented.

AFAICT "Endpoint" isn't specific enough WSDLese, no newbie and very few novices are going to understand where to find it in the WSDL.    The benefit of "portName" is that it is precisely its name in the WSDL (just like we have a clear-to-understand "serviceName" attribute in the same jaxws:endpoint element.)  "endpointName" seems to be unnecessary synonym-creating, which makes things more confusing for the user.  After all, is it not the case that "endpointName" would be as relevant for the service name as it is for the port name?


> Spring Config of portName and serviceName does not work
> -------------------------------------------------------
>
>                 Key: CXF-507
>                 URL: https://issues.apache.org/jira/browse/CXF-507
>             Project: CXF
>          Issue Type: Bug
>          Components: Configuration, JAX-WS Runtime
>    Affects Versions: 2.0-RC
>         Environment: Using 2.0-RC SNAPSHOT
>            Reporter: Chris Moesel
>            Assignee: Dan Diephouse
>             Fix For: 2.0.4
>
>
> The documentation at the following page indicates that a portName and serviceName can be specified as attributes in <jaxws:endpoint> in the spring config file:
> http://cwiki.apache.org/CXF20DOC/jax-ws-configuration.html
> There are two issues:
> 1)  If the portName and serviceName are specified as recommended in the documentation, Spring does not properly parse the config file, due to the following exception:
> org.xml.sax.SAXParseException: cvc-datatype-valid.1.2.1: '{http://mycompany.com/products/webservice}MyServicePort' is not a valid value for 'QName'.
> I was able to get it to parse by adding the following to the root beans element:
> xmlns:mws="http://mycompany.com/products/webservice"
> And then specifying the portName like so: "mws:MyServicePort"
> 2)  Once you've gotten past #1 above,  you get the following error:
> org.springframework.beans.NotWritablePropertyException: Invalid property 'portName' of bean class [org.apache.cxf.jaxws.spring.EndpointFactoryBean]: Bean property 'portName' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
> Looking at the source code, it appears there are no setters for portName or serviceName:
> http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/spring/EndpointFactoryBean.java?view=markup

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (CXF-507) Spring Config of portName and serviceName does not work

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

Daniel Kulp resolved CXF-507.
-----------------------------

       Resolution: Fixed
    Fix Version/s: 2.0.4


I'm pretty sure this is now resolved:

For point 1: that wiki page has been updated with the proper form for the QNames

For point 2: the wiki page has also been updated to reflect that the proper name is "endpointName", not "portName".   "endpointName" is what is specified in the schema.



> Spring Config of portName and serviceName does not work
> -------------------------------------------------------
>
>                 Key: CXF-507
>                 URL: https://issues.apache.org/jira/browse/CXF-507
>             Project: CXF
>          Issue Type: Bug
>          Components: Configuration, JAX-WS Runtime
>    Affects Versions: 2.0-RC
>         Environment: Using 2.0-RC SNAPSHOT
>            Reporter: Chris Moesel
>            Assignee: Dan Diephouse
>             Fix For: 2.0.4
>
>
> The documentation at the following page indicates that a portName and serviceName can be specified as attributes in <jaxws:endpoint> in the spring config file:
> http://cwiki.apache.org/CXF20DOC/jax-ws-configuration.html
> There are two issues:
> 1)  If the portName and serviceName are specified as recommended in the documentation, Spring does not properly parse the config file, due to the following exception:
> org.xml.sax.SAXParseException: cvc-datatype-valid.1.2.1: '{http://mycompany.com/products/webservice}MyServicePort' is not a valid value for 'QName'.
> I was able to get it to parse by adding the following to the root beans element:
> xmlns:mws="http://mycompany.com/products/webservice"
> And then specifying the portName like so: "mws:MyServicePort"
> 2)  Once you've gotten past #1 above,  you get the following error:
> org.springframework.beans.NotWritablePropertyException: Invalid property 'portName' of bean class [org.apache.cxf.jaxws.spring.EndpointFactoryBean]: Bean property 'portName' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
> Looking at the source code, it appears there are no setters for portName or serviceName:
> http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/spring/EndpointFactoryBean.java?view=markup

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CXF-507) Spring Config of portName and serviceName does not work

Posted by "Eugene Gavrilov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12554059 ] 

Eugene Gavrilov commented on CXF-507:
-------------------------------------

I'm facing the same issue with 2.0.3. 
As the sample is mentioned in documentation so it's very strange to see this defect opened for 9 months. 
It's the first issue I found right after start with CXF. What are the suggested workarounds?

> Spring Config of portName and serviceName does not work
> -------------------------------------------------------
>
>                 Key: CXF-507
>                 URL: https://issues.apache.org/jira/browse/CXF-507
>             Project: CXF
>          Issue Type: Bug
>          Components: Configuration, JAX-WS Runtime
>    Affects Versions: 2.0-RC
>         Environment: Using 2.0-RC SNAPSHOT
>            Reporter: Chris Moesel
>            Assignee: Dan Diephouse
>
> The documentation at the following page indicates that a portName and serviceName can be specified as attributes in <jaxws:endpoint> in the spring config file:
> http://cwiki.apache.org/CXF20DOC/jax-ws-configuration.html
> There are two issues:
> 1)  If the portName and serviceName are specified as recommended in the documentation, Spring does not properly parse the config file, due to the following exception:
> org.xml.sax.SAXParseException: cvc-datatype-valid.1.2.1: '{http://mycompany.com/products/webservice}MyServicePort' is not a valid value for 'QName'.
> I was able to get it to parse by adding the following to the root beans element:
> xmlns:mws="http://mycompany.com/products/webservice"
> And then specifying the portName like so: "mws:MyServicePort"
> 2)  Once you've gotten past #1 above,  you get the following error:
> org.springframework.beans.NotWritablePropertyException: Invalid property 'portName' of bean class [org.apache.cxf.jaxws.spring.EndpointFactoryBean]: Bean property 'portName' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
> Looking at the source code, it appears there are no setters for portName or serviceName:
> http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/spring/EndpointFactoryBean.java?view=markup

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.