[JBossWS] - Webservice and transaction annotations
by timdyck
I am currently developing a webservice endpoint using the JbossWS annotations and transaction annotations and I am encountering a problem that I need some help on.
It seems that when I add in the annotations for transactions then I get the following stack trace message when running in JBoss AS 4.0.4.GA:
| java.lang.RuntimeException: Unable to find method public org.jboss.aop.InstanceAdvisor com.discorp.licensing.server.LicenseServer._getInstanceAdvisor() descriptor=()Lorg/jboss/aop/InstanceAdvisor;
| at org.jboss.lang.AnnotationHelper.getCtMethod(AnnotationHelper.java:214)
| at org.jboss.lang.AnnotationHelper.getAnnotations(AnnotationHelper.java:164)
| at org.jboss.lang.AnnotationHelper.getAnnotation(AnnotationHelper.java:145)
| at org.jboss.lang.AnnotationHelper.isAnnotationPresent(AnnotationHelper.java:130)
| at org.jboss.ws.metadata.AnnotationsMetaDataBuilder.setupEndpointFromAnnotations(AnnotationsMetaDataBuilder.java:152)
| at org.jboss.ws.metadata.AnnotationsMetaDataBuilderJSE.buildMetaData(AnnotationsMetaDataBuilderJSE.java:82)
| at org.jboss.ws.server.WebServiceDeployerJSE.createWebServicesMetaData(WebServiceDeployerJSE.java:196)
| at org.jboss.ws.server.WebServiceDeployer.create(WebServiceDeployer.java:103)
| at org.jboss.ws.server.WebServiceDeployerJSE.create(WebServiceDeployerJSE.java:66)
| at org.jboss.deployment.SubDeployerInterceptorSupport$XMBeanInterceptor.create(SubDeployerInterceptorSupport.java:180)
| at org.jboss.deployment.SubDeployerInterceptor.invoke(SubDeployerInterceptor.java:91)
| 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 $Proxy31.create(Unknown Source)
| at org.jboss.deployment.MainDeployer.create(MainDeployer.java:953)
| at org.jboss.deployment.MainDeployer.create(MainDeployer.java:943)
| at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:807)
| at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:771)
| at sun.reflect.GeneratedMethodAccessor55.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 $Proxy8.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.startService(AbstractDeploymentScanner.java:336)
| at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
| at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
| at sun.reflect.GeneratedMethodAccessor2.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.server.Invocation.invoke(Invocation.java:86)
| at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
| at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
| at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
| at $Proxy0.start(Unknown Source)
| at org.jboss.system.ServiceController.start(ServiceController.java:417)
| at sun.reflect.GeneratedMethodAccessor9.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.server.Invocation.invoke(Invocation.java:86)
| 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 $Proxy4.start(Unknown Source)
| at org.jboss.deployment.SARDeployer.start(SARDeployer.java:302)
| at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1007)
| at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:808)
| at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:771)
| at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:755)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| 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 $Proxy5.deploy(Unknown Source)
| at org.jboss.system.server.ServerImpl.doStart(ServerImpl.java:482)
| at org.jboss.system.server.ServerImpl.start(ServerImpl.java:362)
| at org.jboss.Main.boot(Main.java:200)
| at org.jboss.Main$1.run(Main.java:464)
| at java.lang.Thread.run(Thread.java:595)
| Caused by: javassist.NotFoundException: _getInstanceAdvisor(..) is not found in com.discorp.licensing.server.LicenseServer
| at javassist.CtClassType.getMethod(CtClassType.java:890)
| at org.jboss.lang.AnnotationHelper.getCtMethod(AnnotationHelper.java:210)
| ... 83 more
|
Here is my class file code (a shorten version of it):
| imports here...
|
| @WebService(name = "LicenseServer",
| targetNamespace = "urn:LicenseServer")
| @SOAPBinding(style = SOAPBinding.Style.DOCUMENT,
| use = SOAPBinding.Use.LITERAL)
| public class LicenseServer
| {
| private static final Logger _logger = Logger.getLogger(LicenseServer.class);
|
| public LicenseServer() {}
|
| /**
| * Takes in a ClientIdRequest object and generates a ClientId.
| *
| */
| @WebMethod(operationName = "GetClientId")
| @WebResult(name = "ProcessClientId")
| @Tx(TxType.REQUIRED)
| public ProcessClientId getClientID(
| @WebParam(name="ClientIdRequest") ClientIdRequest clientIdRequest)
| throws LicenseServerException
| {
| _logger.info(clientIdRequest);
|
| ClientDO clientDO = LicenseServerDAO.getInstance().getClientDO(clientIdRequest);
|
| //more code...
| }
|
| /**
| * Gets leases for the software ids specified by the client.
| *
| */
| @WebMethod(operationName = "ProcessLeaseRequest")
| @WebResult(name = "LeaseResponse")
| @Tx(TxType.REQUIRED)
| public Lease[] processLeaseRequest(
| @WebParam(name="ClientId") String clientId,
| @WebParam(name="AssetIds") String[] assetIds,
| @WebParam(name="AdditionInfo") Map additionalInfo)
| throws LicenseServerException
| {
| _logger.info("processLeaseRequest");
|
| //more code...
| }
| }
|
If I remove the transaction stuff and put them on another class then it seems to work fine, though I really need to have the transaction stuff on these methods since they are the entry points. Any ideas as to why it is not working or am I doing something wrong?
I am using jboss-aop-jdk50.deployer for the aop stuff. Let me know if I need to provide more information then what I have.
Thanks,
Tim.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3977735#3977735
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3977735
19 years, 7 months
[JBossCache] - OutOfMemory errors using jgroup 2.2.9.1
by spanuganti@saba.com
I am using jgroups in a clustered application for distributed caching of frequently used objects. The application is deployed on JBoss, websphere and weblogic. I have noticed that the system occassionally runs out of memory and has full gc's after running for a couple of days. On the websphere cluster deployment I inspected the heap dumps generated. These dumps show that there are about 200,000 objects in org/groups/util/Queue$Element holding up about 1GB memory. It seems that jgroups are holding on to these objects and are not getting gc'ed.
Does anybody know if this is a known issue?
I suspect there is some message that is being sent repeatedly. Can we limit the number of retries with a configuration setting?
I am running this on
websphere ND 5.1.1.6 ( on Redhat Linux )
IBM jdk 1.4.2.
jgroup 2.2.9.1
min and max memory setting in the app server is 256m and 1536m
jgroup config properties
UDP(mcast_addr=237.0.0.101;mcast_port=7500;ip_ttl=32;mcast_send_buf_size=150000;mcast_recv_buf_size=80000):PING(timeout=2000;num_initial_members=3):MERGE2(min_interval=5000;max_interval=10000):FD_SOCK:VERIFY_SUSPECT(timeout=1500):pbcast.NAKACK(gc_lag=50;retransmit_timeout=300,600,1200,2400,4800):UNICAST(timeout=600,1200,2400):pbcast.STABLE(desired_avg_gossip=20000):FRAG(frag_size=4096;down_thread=false;up_thread=false):pbcast.GMS(join_timeout=5000;join_retry_timeout=2000;shun=false;print_local_addr=true)
Any help appreciated.
Thanks,
Srinivas
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3977733#3977733
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3977733
19 years, 7 months
[JBossWS] - Re: implementing wsse:UserNameToken
by jason.greene@jboss.com
"kdeboer" wrote : I did some research in the JBoss WS 103 Sources.
| It appears that the username token profile is partly supported.
| The user and password are added to the soap header when the password are added to the call or proxy object
| However password type attribute and password encoding is not support.
| According to the basic security profile the type attribute is required.
| Password disgest is also very nice to have.
|
| will these functions be added in the near future?
|
The basic security profile has been in draft for over a year, and is not expected to be finalized anytime soon so we haven't looked at conforming to it. WS-Security 1.0 has type as optional, so we dont specify it. The encoding type is only relevant to a Nonce. and as you see currently nonces aren't supported. I have updated the feature request to reflect this.
Currently the priority on this is low, since we are busy working on EE5 / JAX-WS. So, as Thomas said, feel free to contribute if you want to see this sooner.
-Jason
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3977728#3977728
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3977728
19 years, 7 months