[jbossws-issues] [JBoss JIRA] Created: (JBWS-2283) org.jboss.ws.WSException: <param> is not a valid property error if two webservices (from different beans but same package) with same method signature has different webparam(name) value.

Markus Schulz (JIRA) jira-events at lists.jboss.org
Wed Aug 13 10:06:40 EDT 2008


org.jboss.ws.WSException: <param> is not a valid property error if two webservices (from different beans but same package) with same method signature has different webparam(name) value.
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

                 Key: JBWS-2283
                 URL: https://jira.jboss.org/jira/browse/JBWS-2283
             Project: JBoss Web Services
          Issue Type: Bug
      Security Level: Public (Everyone can see)
          Components: jbossws-native
    Affects Versions: jbossws-native-3.0.1
         Environment: Debian/Etch x32
java version "1.5.0_14"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_14-b03)
Java HotSpot(TM) Server VM (build 1.5.0_14-b03, mixed mode)

            Reporter: Markus Schulz


example to reproduce.

class 1:
package abc;
@Stateless(name="ws1")
@WebService(targetNamespace="http://example.org")
public class ws1 {
	@WebMethod(operationName="method1")
	public String method1(@WebParam(name="param1") int arg1, @WebParam(name="param2") int arg2) {
		return "TEST-WS1-Method1";
	}
}

class 2:
package abc;
@Stateless(name="ws2")
@WebService(targetNamespace="http://example.org")
public class ws2  {

	@WebMethod(operationName="method1")
	public String method1(@WebParam(name="param1_new") int arg1, @WebParam(name="param2_new") int arg2) {
		return "TEST-WS2-Method1";
	}
}

it's impossible to deploy this sample:
15:54:28,008 ERROR [MainDeployer] Could not start deployment: file:/home/nias/prog/jboss/server/default/tmp/deploy/tmp5876assek.ear-contents/assek.jar
org.jboss.ws.WSException: param1_new is not a valid property on class abc.jaxws.Method1
        at com.sun.xml.bind.v2.runtime.JAXBContextImpl.getElementPropertyAccessor(JAXBContextImpl.java:926)
        at org.jboss.ws.metadata.accessor.JAXBAccessorFactory.create(JAXBAccessorFactory.java:51)
        at org.jboss.ws.metadata.umdm.EndpointMetaData.createAccessor(EndpointMetaData.java:713)
        at org.jboss.ws.metadata.umdm.EndpointMetaData.eagerInitializeAccessors(EndpointMetaData.java:694)
        at org.jboss.ws.metadata.umdm.EndpointMetaData.initializeInternal(EndpointMetaData.java:567)
        at org.jboss.ws.metadata.umdm.EndpointMetaData.eagerInitialize(EndpointMetaData.java:553)
        at org.jboss.ws.metadata.umdm.ServiceMetaData.eagerInitialize(ServiceMetaData.java:435)
        at org.jboss.ws.metadata.umdm.UnifiedMetaData.eagerInitialize(UnifiedMetaData.java:196)
        at org.jboss.wsf.stack.jbws.EagerInitializeDeploymentAspect.create(EagerInitializeDeploymentAspect.java:50)
        at org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl.deploy(DeploymentAspectManagerImpl.java:118)
        at org.jboss.wsf.container.jboss42.ArchiveDeployerHook.deploy(ArchiveDeployerHook.java:97)
        at org.jboss.wsf.container.jboss42.DeployerInterceptor.start(DeployerInterceptor.java:90)
        at org.jboss.deployment.SubDeployerInterceptorSupport$XMBeanInterceptor.start(SubDeployerInterceptorSupport.java:188)
        at org.jboss.deployment.SubDeployerInterceptor.invoke(SubDeployerInterceptor.java:95)
        at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
        at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
        at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
        at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
        at $Proxy34.start(Unknown Source)
        at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1025)
        at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1015)
        at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:819)
        at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782)
        at sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
        at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
        at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)
        at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
        at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)
        at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
        at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
        at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
        at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
        at $Proxy9.deploy(Unknown Source)
        at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:421)
        at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:634)
        at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:263)
        at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:274)
        at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:225)


error caused by: w2.method1 has @WebParam(name) with a name (param1_new) different from ws1.method1 but has the same java-method-signature.
But both webservices should be independent and it should be possible to have same methods with different @WebParam names.
If i'm put the second WS to another package, the error disappears.


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jbossws-issues mailing list