[EJB 3.0] - EJB3 MBean does not support NotificationBroadcaster
by jc7442
I use EMBEDDED_JBOSS_BETA3
I deploy a MBean EJB3
@Service(objectName = InstrumentManagerMBean.MDBName)
| @Management(InstrumentManagerMBean.class)
| public class InstrumentManagerImpl extends NotificationBroadcasterSupport
| implements InstrumentManagerMBean {...
|
When I try to add a notification listener I have an exception:
MBeanServer mbs = (MBeanServer) MBeanServerFactory.findMBeanServer(null).iterator().next();
| ObjectName oName = new ObjectName(InstrumentManagerMBean.MDBName);
| System.out.println(mbs.isRegistered(oName));
| mbs.addNotificationListener(oName, new ClientListener(), null, null);
Exception in thread "main" javax.management.RuntimeOperationsException
| at org.jboss.mx.server.MBeanServerImpl.addNotificationListener(MBeanServerImpl.java:749)
| at fr.biomerieux.nextgen.commandexecutor.Main.main(Main.java:50)
| Caused by: java.lang.IllegalArgumentException: The MBean nextGen:service=InstrumentManagerMBean exists but does not implement the NotificationBroadcaster interface.
| ... 2 more
Object rerieved in MBeanServerImpl is a ServiceMBeanDelegate . It is a delegate around my MBean. This delegate does not implement the NotificationBroadcaster . Consequently I cannot register to notification listeners.
Any idea to fix that issue ? I looks like an defect.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4205142#4205142
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4205142
17 years, 2 months
[Clustering/JBoss] - Re: Strange behavior replicated session (Error)
by rengar
anonymous wrote : Do you mean with AS 4.2.3 it's always xxxxxxxxxxxx.node1? Even after you shut down node1?
Yes
anonymous wrote :
| If so, do you have "UseJK" set to "true" in your 4.2.3 deploy/jboss-web-deployer/META-INF/jboss-service.xml file? You should.
|
I have useJK="true".
anonymous wrote :
| If you can make that happen in 4.2.3 and then you see the same "bad" behavior that tells me it is an issue with how mod_proxy deals with the jvmRoute suffix.
|
I use the same apache-mod_proxy at 4.2.3 and 5.0.0.
My configuration:
1.- Apache
| <VirtualHost *:80>
|
| <Proxy balancer://portalcluster>
| Order deny,allow
| Allow from all
|
| BalancerMember ajp://10.20.2.110:8009 route=node1
| BalancerMember ajp://10.20.2.111:8009 route=node2
| BalancerMember ajp://10.20.2.112:8009 route=node3
| </Proxy>
|
| ProxyPass / balancer://portalcluster/ stickysession=JSESSIONID nofailover=Off
| </VirtualHost>
|
2.- JBoss web (at 3 nodes - node1,node2,node3)
-"/opt/java/jboss/server/all/deploy/jboss-web.deployer/server.xml"
| <Engine .... jvmRoute="node1">
|
| <Engine .... jvmRoute="node2">
|
| <Engine .... jvmRoute="node3">
|
-"/opt/java/jboss/server/all/deploy/jboss-web.deployer/META-INF/jboss-service.xml" (this step only 4.2.3, not at 5.0.0 (don't necessary))
| <attribute name="UseJK">true</attribute>
|
At 5.0.0 have a strange behaviour when it returns node1 because change session to yyyyyyyyyyyyyyy.node1 (New session). Before session were xxxxxxxxxxxxxxx.node1. Don't reused the same session.
Thanks.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4205133#4205133
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4205133
17 years, 2 months
[Beginners Corner] - JBoss Tools eclipse issue
by blewinski
Hello -
I am trying to get JBoss Tools working in eclipse ganymede. I did a manual install copying the downloaded plugins and features into the eclipse plugins and features directory. I did a eclipse -clean before restarting. After I create a base web project (I am trying to create a JSR286 portlet from a tutorial I found) I try to add a portlet to it. When I click Choose File>New>Other and then select the JBoss Web Tools>Portlet wizard I do not see any options for JBoss. I would appreciate an insight as to how I can get this working. I there is a better way to install JBoss Tools to an existing eclipse install I can try to reinstall. I previously tried to install via the eclipse Update Manager with no success.
Thanks in advance!
Brett
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4205121#4205121
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4205121
17 years, 2 months
[Clustering/JBoss] - Re: Very strange problem while looking up HAJMS Topic
by bstansberry@jboss.com
OK, I see what's going on here. The key difference between your two stack traces is the thread involved. In the NNFE case, it's the JGroups thread that carries messages up from the network. You then use the thread to instantiate an SLSB, which then does an HA-JNDI lookup, which makes a group RPC to the cluster and then blocks waiting for responses.
Problem is the response to that group RPC will not be received because the thread that needs to carry the response up from the network is the same JGroups thread that is blocking waiting for the response! What will happen is the JGroups thread will block 60 secs waiting for a response, never get one, and then return, following which HA-JNDI throws the NNFE.
Bottom line -- don't call back into the cluster from a JGroups thread. Somewhere in here you need pass a task to another thread to let it invoke on the SLSB so the JGroups thread can return.
| 10:23:13,051 ERROR [STDERR] at $Proxy462.startManagers(Unknown Source)
| 10:23:13,051 ERROR [STDERR] at com.navineo.sa.jmx.ha.taches.ComEmbarquesHAS.doDemarrerTacheEgoiste(
| ComEmbarquesHAS.java:19)
| 10:23:13,051 ERROR [STDERR] at com.navineo.sa.jmx.ha.taches.core.TacheEgoisteHAS.doDemarrer(TacheEg
| oisteHAS.java:16)
| 10:23:13,051 ERROR [STDERR] at com.navineo.sa.jmx.ha.HAS.demarrer(HAS.java:25)
| 10:23:13,051 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| 10:23:13,051 ERROR [STDERR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl
| .java:39)
| 10:23:13,051 ERROR [STDERR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcce
| ssorImpl.java:25)
| 10:23:13,051 ERROR [STDERR] at java.lang.reflect.Method.invoke(Method.java:597)
| 10:23:13,051 ERROR [STDERR] at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatc
| her.java:155)
| 10:23:13,051 ERROR [STDERR] at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
| 10:23:13,051 ERROR [STDERR] at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
| 10:23:13,051 ERROR [STDERR] at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker
| .java:264)
| 10:23:13,051 ERROR [STDERR] at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
|
| 10:23:13,051 ERROR [STDERR] at com.navineo.sa.jmx.ha.topologychange.taches.cmd.CommandeRepartitionS
| upport.executerLocalement(CommandeRepartitionSupport.java:54)
| 10:23:13,052 ERROR [STDERR] at com.navineo.sa.jmx.ha.taches.notification.basculement.BasculeTachesE
| goistesHANB$1.handleNotification(BasculeTachesEgoistesHANB.java:90)
| 10:23:13,052 ERROR [STDERR] at org.jboss.mx.util.JBossNotificationBroadcasterSupport.handleNotifica
| tion(JBossNotificationBroadcasterSupport.java:127)
| 10:23:13,052 ERROR [STDERR] at org.jboss.mx.util.JBossNotificationBroadcasterSupport.sendNotificati
| on(JBossNotificationBroadcasterSupport.java:108)
| 10:23:13,052 ERROR [STDERR] at org.jboss.ha.jmx.HAServiceMBeanSupport._receiveRemoteNotification(HA
| ServiceMBeanSupport.java:476)
|
The other one works because it's a JBoss Web thread making the call.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4205119#4205119
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4205119
17 years, 2 months