[JBoss Web Services] - How to override “webServiceHost” property for a single web service, JBoss 4.2.3GA
by Martin Jondzic
Martin Jondzic [http://community.jboss.org/people/hordak83] created the discussion
"How to override “webServiceHost” property for a single web service, JBoss 4.2.3GA"
To view the discussion, visit: http://community.jboss.org/message/613885#613885
--------------------------------------------------------------
Hello,
I need to override the "end-point-machine-IP-address" for a single Web service, which is deployed on JBoss. I know that JBoss overrides the endpoint addresses from WSDL for all deployed WS, using the value of webServiceHost property, when the property modifySOAPAddress, located in file \jboss-4.2.3.GA\server\default\deploy\jbossws.sar\jbossws.beans\META-INF\jboss-beans.xml, is set to true:
<property name="modifySOAPAddress">true</property>
<property name="webServiceHost">${jboss.bind.address}</property>
Now, I have to figure out how to override this behavior for a particular Web service, without changing current configuration.
In other word, for all Web services deployed on JBoss I would like to have the end point prefix specified by webServiceHost property, except for one. I have already read https://issues.jboss.org/browse/JBWS-157 https://issues.jboss.org/browse/JBWS-157, but it doesn't give the answer, just the conformation that this configuration will be available in the next release.
Is that even possible to do?
Thank you!
Martin
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/613885#613885]
Start a new discussion in JBoss Web Services at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
12 years, 11 months
[JBoss AOP] - Mark all Stateless EJBs as part of cluster using ejb3-interceptors-aop.xml
by Nitin Jain
Nitin Jain [http://community.jboss.org/people/nitin_jain] created the discussion
"Mark all Stateless EJBs as part of cluster using ejb3-interceptors-aop.xml"
To view the discussion, visit: http://community.jboss.org/message/613833#613833
--------------------------------------------------------------
Hello Forum,
I am running my application in a clustered environment. I would like to avoid annotating every stateless EJB with @Clustered annotation and rather make use of "ejb3-interceptors-aop.xml".
When I use @Clustered annotation, the annotated EJB is logged by JBoss in the following manner.
2011-07-07 10:06:18,251 INFO [org.jboss.ejb3.deployers.JBossASKernel] (main) Added bean(jboss.j2ee:ear=myapp.ear,jar=platform-services-ejbs.jar,name=NotificationProcessorBean,service=EJB3) to KernelDeployment of: platform-services-ejbs.jar
2011-07-07 10:06:18,251 INFO [org.jboss.ejb3.deployers.JBossASKernel] (main) installing bean: jboss.j2ee:ear=myapp.ear,jar=platform-services-ejbs.jar,name=RequestDispatcherBean,service=EJB3
2011-07-07 10:06:18,251 INFO [org.jboss.ejb3.deployers.JBossASKernel] (main) with dependencies:
2011-07-07 10:06:18,251 INFO [org.jboss.ejb3.deployers.JBossASKernel] (main) and demands:
2011-07-07 10:06:18,251 INFO [org.jboss.ejb3.deployers.JBossASKernel] (main) jboss.ejb:service=EJBTimerService
2011-07-07 10:06:18,251 INFO [org.jboss.ejb3.deployers.JBossASKernel] (main) partition:partitionName=MyCluster
2011-07-07 10:06:18,251 INFO [org.jboss.ejb3.deployers.JBossASKernel] (main) and supplies:
2011-07-07 10:06:18,251 INFO [org.jboss.ejb3.deployers.JBossASKernel] (main) Class:com.myapp.platform.bs.SampleEJB
2011-07-07 10:06:18,251 INFO [org.jboss.ejb3.deployers.JBossASKernel] (main) jndi:myapp/SampleEJBBean/remote-com.myapp.platform.bs.SampleEJB
2011-07-07 10:06:18,251 INFO [org.jboss.ejb3.deployers.JBossASKernel] (main) jndi:myapp/SampleEJBBean/remote
>From the log it can be understood that "SampleEJBBean" is part of "MyCluster".
Is it possible to add annotation element for @Clustered annotation in "ejb3-interceptors-aop.xml" and achieve similar functionality?
To give it a try I added the following elements in the "ejb3-interceptors-aop.xml" file present at "\server\all\deploy" with no success.
<domain name="Stateless Bean" extends="Intercepted Bean" inheritBindings="true">
<bind pointcut="execution(public * *->*(..))>
<interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
<interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
</bind>
<bind pointcut="execution(public * @org.jboss.ejb3.annotation.SecurityDomain->*(..))>
<interceptor-ref name="Basic Authorization"/>
</bind>
<bind pointcut="execution(public * *->*(..))>
<interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
</bind>
<bind pointcut="execution(public * @org.jboss.ejb3.annotation.Clustered->*(..))>
<interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
</bind>
<bind pointcut="execution(public * *->*(..))>
<interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
<interceptor-ref name="org.jboss.ejb3.tx.CMTTxInterceptorFactory"/>
<interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
<interceptor-ref name="org.jboss.ejb3.tx.BMTTxInterceptorFactory"/>
<interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
<interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
<!-- interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/ -->
<stack-ref name="EJBInterceptors"/>
</bind>
<annotation expr="class(*) AND !class((a)org.jboss.ejb3.annotation.Pool)">
@org.jboss.ejb3.annotation.Pool (value=ThreadlocalPool, maxSize=30, timeout=10000)
</annotation>
<annotation expr="class((a)javax.ejb.Remote) AND !class((a)org.jboss.annotation.ejb.Clustered)">
@org.jboss.annotation.ejb.Clustered(partition=MyCluster, loadBalancePolicy=org.jboss.ha.framework.interfaces.RandomRobin")
</annotation>
</domain>
I have tried other possiblities like
<annotation expr="class(*) AND !class((a)org.jboss.annotation.ejb.Clustered)">
@org.jboss.annotation.ejb.Clustered(partition=MyCluster, loadBalancePolicy=org.jboss.ha.framework.interfaces.RandomRobin)
</annotation>
and
<annotation expr="!class((a)org.jboss.annotation.ejb.Clustered)"> @org.jboss.annotation.ejb.Clustered(partition=MyCluster, loadBalancePolicy=org.jboss.ha.framework.interfaces.RandomRobin)
</annotation>
but with no success. I do not see any of my other stateless EJB with a similar log as depicted for "SampleEJBBean".
Please advise on how to fix this issue.
Regards,
Nitin
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/613833#613833]
Start a new discussion in JBoss AOP at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
12 years, 11 months