[JBossWS] - WebMethod with name
by lavrenych
I have method with name "Update" in my WebService class and unable to deploy it. Once I rename it ( "Update1"?), everything runs fine.
More info:
I am getting when deploying:
2007-06-10 12:22:39,409 ERROR [org.jboss.ws.core.server.ServiceEndpointDeployer]
Cannot start service endpoint org.jboss.ws.WSException: param1 is not a valid property on class com.newxt.ws.jaxws.Update
at com.sun.xml.bind.v2.runtime.JAXBContextImpl.getElementPropertyAccesso
r(JAXBContextImpl.java:816)
For this class:
package com.newxt.ws;
import javax.jws.WebMethod;
import javax.jws.WebParam;
import javax.jws.WebService;
@WebService
public class Echo {
@WebMethod
public String echo(String input)
{
return input;
}
@WebMethod
public String Update(
@WebParam (name="param1") String param1)
{
return param1;
}
}
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4052920#4052920
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4052920
17 years, 6 months
[JBossWS] - Problem marshalling data from a List
by gryffin
I have a problem sending a list of item to a client.
I send an object, which contains a member that itself stores a list of device objects. These objects store a member that is either a tag or a network device. ( I don't get to define the WSDL or Schema. )
I confirm that my List object does store a collection of devices which each in turn have a tag.
| 13:58:54,126 DEBUG [AssociationValuesDAO] Device.deviceList:
| [com.boeing.nmt.types.DeviceData$Device$AeroScoutTag@18a5d49,
| com.boeing.nmt.types.DeviceData$Device$AeroScoutTag@f2a0ef,
| com.boeing.nmt.types.DeviceData$Device$AeroScoutTag@123b9c1,
| com.boeing.nmt.types.DeviceData$Device$AeroScoutTag@786e16,
| com.boeing.nmt.types.DeviceData$Device$AeroScoutTag@838143,
| com.boeing.nmt.types.DeviceData$Device$AeroScoutTag@19b7dfa,
| com.boeing.nmt.types.DeviceData$Device$AeroScoutTag@16bb63e,
| com.boeing.nmt.types.DeviceData$Device$AeroScoutTag@89e0c6,
| com.boeing.nmt.types.DeviceData$Device$AeroScoutTag@3fcfb]
|
I send this across the wire ( server and client are local ). I unpack it and everything works great Until I try to access the tags inside the device objects in the List.
They're NULL.
| [java] device list: [com.boeing.nmt.client.ws.DeviceData$Device@102a0a5, com.boeing.nmt.client.
| ws.DeviceData$Device@180b22e, com.boeing.nmt.client.ws.DeviceData$Device@31fb31, com.boeing.nmt.clie
| nt.ws.DeviceData$Device@162522b, com.boeing.nmt.client.ws.DeviceData$Device@89dd, com.boeing.nmt.cli
| ent.ws.DeviceData$Device@15b1773, com.boeing.nmt.client.ws.DeviceData$Device@160bf50, com.boeing.nmt
| .client.ws.DeviceData$Device@b05236, com.boeing.nmt.client.ws.DeviceData$Device@1e55794]
| [java] device list size: 9
| [java] dev[1]: com.boeing.nmt.client.ws.DeviceData$Device@102a0a5
| [java] Exception! java.lang.NullPointerException
|
I trigger the exception this way:
| List <DeviceData.Device> devList = aagr.getAssociationValues().getDeviceData().getDevice();
| System.out.println("device list: " + devList.toString() );
| System.out.println("device list size: " + devList.size() );
| // devList.toArray()[0] is a DeviceData.Device.Tag object, for whatever reason, it's NULL
| System.out.println("dev[1]: " + devList.toArray()[0].toString());
| System.out.println("dev[1]: " + ((DeviceData.Device)devList.toArray()[0]).toString());
|
I look back at the logs to see what JBoss is unmarshalling, and it looks fine.
2007-06-08 13:58:54,158 DEBUG [org.jboss.ws.core.soap.ObjectContent] xmlFragment: [source=
| <Results xmlns:ns2="http://www.boeing.com/NLS/ns/Types" xmlns:ns3="http://www.boeing.com/NLS/ns/soapTypes" Version="0.3.0">
| <ns3:AssociationReturnCode>
| <ns3:Success>true</ns3:Success>
| <ns3:Reason>Dumb luck</ns3:Reason>
| </ns3:AssociationReturnCode>
| <ns3:AssociationValues DeleteOtherDeviceAssociations="false" CreateDeviceAssociations="NONE">
| <ns3:DeviceData Version="0.3.0">
| <ns2:Device xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="ns2:AeroScoutTag" MacId="000CCC654323">
| <ns2:BatteryStatus>Unknown
| </ns2:BatteryStatus>
| </ns2:Device>
| ...
| </ns3:DeviceData>
| <ns3:AssetData Version="0.3.0" OwnerAppId="foo" AssetId="fah">
| <ns2:AssetDisplayName>gah</ns2:AssetDisplayName>
| <ns2:AssetDescription>fah</ns2:AssetDescription>
| <ns2:AssetSuspended>true</ns2:AssetSuspended>
| </ns3:AssetData>
| </ns3:AssociationValues>
| </Results>
| ]
| 2007-06-08 13:58:54,158 DEBUG [org.jboss.ws.core.soap.SOAPContentElement] -----------------------------------
| 2007-06-08 13:58:54,220 DEBUG [org.jboss.ws.core.soap.MessageContextAssociation] popMessageContext: org.jboss.ws.core.jaxws.handler.SOAPMessageContextJAXWS@131a24c (Thread http-0.0.0.0-8080-2)
I'm using JBoss 4.0.5 w/ JBossWS 1.2.0. Does anyone have an idea what am I missing?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4052753#4052753
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4052753
17 years, 6 months
[JBossWS] - Problem with String Array in WSDL generated in 4.0.5GA
by tballerstein
I am new to JBoss and deploying web services. I am trying to convert are old web services from ATG Platform to JBOSS 4.0.5GA. I have eveything converted to work with JBoss. I have a couple of services deployed and work properly. However I have a couple of services that do not work because one of the datatypes in the object that is being passed is a string array. When the array is passed to the server the array is null. I looked at the wsdl generated and it seems that wsdl generated did not recognize the string array. Here is the part of the wsdl. Entries is my String Array.
element maxOccurs="unbounded" minOccurs="0" name="entries" nillable="true" type="string"
When I deployed the service I simply deployed the jar file I did not actually create the wsdl file using wstools. I let Jboss deploy and generate the wsdl file.
How can I fix this problem.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4052747#4052747
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4052747
17 years, 6 months
[JBossWS] - JBossWS, Portlets, JAAS and Multiple JBoss Application Serve
by hartsock
I'm just starting in on a new project. I have been directed to create a SOAP service that will be consumed by a Portlet. The portal server is on a physically separate server from the JBoss EJB3/SOAP server.
What I want to do is to take the Authenticated Principal from the Portal and pass it back to the server running the SOAP services. How would I do this? I assume that JAAS plays a role and the secret is in a properly configured realm.
The documentation I have assumes the SOAP and Portal programs are on the same server... but these programs are on physically different servers. I can see this being a problem if I have to coordinate authentication between multiple SOAP servers which I know many shops must have to do. So, I figure there must be a straight forward solution that I'm not finding in the JBoss wiki, the JBoss text books I have, or the other training materials.
I'm trying to answer this security question before I start writing application code.
Thanks.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4052678#4052678
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4052678
17 years, 6 months
[JBossWS] - wstools exception in jboss4.2
by johnefranklin@yahoo.com
Hi,
I am attaching a wsdl that used to work nicely with JBoss 4.0.5. But when I try to generate the java files from the wsdl using the wstools shipped along with JBoss 4.2, it keeps giving me this error.
Exception in thread "main" org.jboss.ws.WSException: [JAX-RPC 2.3.1.2] Unable to unwrap model group with multiple particles.
at org.jboss.ws.tools.helpers.ReturnTypeUnwrapper.unwrapModelGroup(ReturnTypeUnwrapper.java:120)
at org.jboss.ws.tools.helpers.ReturnTypeUnwrapper.unwrap(ReturnTypeUnwrapper.java:87)
at org.jboss.ws.tools.WSDLToJava.getReturnType(WSDLToJava.java:632)
at org.jboss.ws.tools.WSDLToJava.appendDocParameters(WSDLToJava.java:395)
at org.jboss.ws.tools.WSDLToJava.appendMethods(WSDLToJava.java:290)
at org.jboss.ws.tools.WSDLToJava.createSEIFile(WSDLToJava.java:588)
at org.jboss.ws.tools.WSDLToJava.createSEI(WSDLToJava.java:618)
at org.jboss.ws.tools.WSDLToJava.generateSEI(WSDLToJava.java:186)
at org.jboss.ws.tools.helpers.ToolsHelper.handleWSDLToJavaGeneration(ToolsHelper.java:303)
at org.jboss.ws.tools.WSTools.process(WSTools.java:137)
at org.jboss.ws.tools.WSTools.generate(WSTools.java:69)
at org.jboss.ws.tools.WSTools.generate(WSTools.java:119)
at org.jboss.ws.tools.WSTools.main(WSTools.java:58)
Can someone please look at the wsdl and point me the problem in the wsdl?
regards,
johnf
| <definitions name="EventMonitoringService" targetNamespace="http://com.ws.test/sample"
| xmlns="http://schemas.xmlsoap.org/wsdl/"
| xmlns:ns2="http://com.ws.test/sample"
| xmlns:tns="http://com.ws.test/sample/types"
| xmlns:xsd="http://www.w3.org/2001/XMLSchema"
| xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
| xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
| xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/">
| <types>
| <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
| targetNamespace="http://com.ws.test/sample/types"
| xmlns:tns="http://com.ws.test/sample/types">
|
| <xsd:simpleType name="DeviceID">
| <xsd:restriction base="xsd:string">
| <xsd:minLength value="0"/>
| </xsd:restriction>
| </xsd:simpleType>
|
| <xsd:complexType name="LogicalEvents">
| <xsd:sequence>
| <xsd:element name="logicalVar1" type="xsd:boolean" minOccurs="0"/>
| <xsd:element name="logicalVar2" type="xsd:boolean" minOccurs="0"/>
| </xsd:sequence>
| </xsd:complexType>
|
| <xsd:complexType name="PhysicalEvents">
| <xsd:sequence>
| <xsd:element name="physicalVar1" type="xsd:boolean" minOccurs="0"/>
| <xsd:element name="physicalVar2" type="xsd:boolean" minOccurs="0"/>
| </xsd:sequence>
| </xsd:complexType>
|
| <xsd:complexType name="FilterEvents">
| <xsd:sequence>
| <xsd:element name="physical" type="tns:PhysicalEvents" minOccurs="0"/>
| <xsd:element name="logical" type="tns:LogicalEvents" minOccurs="0"/>
| </xsd:sequence>
| </xsd:complexType>
|
| <xsd:simpleType name="ErrorValue">
| <xsd:restriction base="xsd:string">
| <xsd:minLength value="0"/>
| </xsd:restriction>
| </xsd:simpleType>
|
| <xsd:complexType name="TestException">
| <xsd:sequence>
| <xsd:element name="errorValue" type="tns:ErrorValue"/>
| <xsd:element name="errorMessage" type="xsd:string" nillable="true"/>
| </xsd:sequence>
| </xsd:complexType>
|
| <xsd:element name="ErrorValue" type="tns:ErrorValue"/>
| <xsd:element name="TestException" type="tns:TestException"/>
|
| <xsd:element name="MonitorEventsRequest">
| <xsd:complexType>
| <xsd:sequence>
| <xsd:element name="deviceID" type="tns:DeviceID"/>
| <xsd:element name="requestFilter" type="tns:FilterEvents" minOccurs="0"/>
| </xsd:sequence>
| </xsd:complexType>
| </xsd:element>
|
| <xsd:element name="MonitorEventsResponse">
| <xsd:complexType>
| <xsd:sequence>
| <xsd:element name="deviceID" type="tns:DeviceID"/>
| <xsd:element name="allotedFilter" type="tns:FilterEvents" minOccurs="0"/>
| </xsd:sequence>
| </xsd:complexType>
| </xsd:element>
| </xsd:schema>
| </types>
|
| <message name="MonitorEventsRequest">
| <part name="parameters" element="tns:MonitorEventsRequest"/>
| </message>
|
| <message name="MonitorEventsResponse">
| <part name="result" element="tns:MonitorEventsResponse"/>
| </message>
|
| <message name="TestException">
| <part name="exception" element="tns:TestException"/>
| </message>
|
| <portType name="EventMonitoringService">
| <operation name="MonitorEventsRequest">
| <input message="ns2:MonitorEventsRequest"/>
| <output message="ns2:MonitorEventsResponse"/>
| <fault name="FaultName" message="ns2:TestException"/>
| </operation>
| </portType>
|
|
| <binding name="EventMonitoringServiceBinding" type="ns2:EventMonitoringService">
| <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/>
| <operation name="MonitorEventsRequest">
| <soap:operation soapAction=""/>
| <input>
| <soap:body use="literal"/>
| </input>
| <output>
| <soap:body use="literal"/>
| </output>
| <fault name="FaultName">
| <soap:fault name="FaultName" use="literal"/>
| </fault>
| </operation>
|
| </binding>
| <service name="EventMonitoringService">
| <port name="EventMonitoringServicePort" binding="ns2:EventMonitoringServiceBinding">
| <soap:address location="http://localhost/test/EventMonitoringService"/>
| </port>
| </service>
|
| </definitions>
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4052646#4052646
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4052646
17 years, 6 months