[JBossWS] - Re: Type Substitution doesn't work with Schema2Java Client a
by mrokka123
WOW! It really works. Thanks a lot Richard.
It even works on JBossWs 1.2.1 [I think Which was default JBossWs for JBoss4.2.0].
Here?s the working version:
POJO Class
A.java
package com.d2.client;
public abstract class A implements java.io.Serializable{
private String name;
public void setName(String name){
this.name=name;
}
public String getName(){
return name;
}
}
B.java
package com.d2.client;
public class B extends A implements java.io.Serializable{
}
package-info.java //this class does the magic
@javax.xml.bind.annotation.XmlSchema(namespace = "http://client.d2.com/")
package com.d2.client;
-------------------------------------------------------------------------------------
WebService
package com.d2.webservice;
import javax.jws.WebService;
import javax.jws.WebMethod;
import javax.jws.soap.SOAPBinding;
import com.d2.client.*;
@WebService(name = "MyWebServicePortType", serviceName = "MyWebService",
portName = "MyWebServicePort",targetNamespace = "http://client.d2.com")
@SOAPBinding(style = SOAPBinding.Style.DOCUMENT,
use = SOAPBinding.Use.LITERAL,
parameterStyle = SOAPBinding.ParameterStyle.WRAPPED)
public class MyWebService{
@WebMethod
public String getClassName(A obj){
System.out.println("class name:"+obj.getClass().getName());
System.out.println("Parent name:"+obj.getName());
return obj.getClass().getName();
}
@WebMethod
public void dummyMethod(B obj)//if we use @XmlSeeAlso then this method not needed
{
}
}
Regards,
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4091427#4091427
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4091427
17 years, 3 months
[JBossWS] - Re: Transaction Not Allowed
by subramaniam.venkat
Hello oskar,
First thanks for replying.
I am using Required transaction attribute when i am creating a transaction with Spring. This behaves the same way as the Required transaction attribute in CMT.
And the transaction attribute in the EJB is also "Required". So in theory there must not be a new transaction which should be created by Spring and the same transaction which has been created by the EJB must be used.
My application runs fine for a long time and then suddenly this error pops up and then all the following request fail with the same error. If Jboss is restart then it is working fine again.
Please let me know your comments.
Thanks & Regards,
Subramaniam V
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4091412#4091412
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4091412
17 years, 3 months