[jboss-jira] [JBoss JIRA] Commented: (JBMESSAGING-1244) GroupMember passes null to Channel.connect()

Brian Stansberry (JIRA) jira-events at lists.jboss.org
Thu Mar 13 11:10:58 EDT 2008


    [ http://jira.jboss.com/jira/browse/JBMESSAGING-1244?page=comments#action_12402711 ] 
            
Brian Stansberry commented on JBMESSAGING-1244:
-----------------------------------------------

I see two different concepts in MessagingPostOfficeService: groupName and channelPartitionName. So let's go through their meaning:

1) The channelPartitionName is used as a qualifier in creating JGroups channels. Uniquely identifies a set of JBM instances that are meant to work together. Specific purpose is to ensure that only JBM instances with the same channelPartitionName form a group and exchange messages.

2) The groupName is used internally in JBM.  I have no idea how or why.  I do see that in the AS 5.0.0.Beta4 JBM configuration groupName is left at 'null'.  This is a *clue* to me that groupName isn't doing much internally.  Just a clue!! I really have no idea.

Perhaps groupName and channelPartitionName really serve the same purpose -- uniquely identifying a set of JBM instances that are meant to work together.  To know if that's the case, you need to find out the purpose of groupName.

If they do have the same purpose, you should probably create a separate JIRA to get rid of channelPartitionName and always use groupName instead.

To resolve this more limited issue, you need to be sure that:

a) when you create a control channel you pass channelPartitionName + "-CTRL" to createMultiplexerChannel
b) when you connect a control channel you use channelPartitionName + "-CTRL" to connect
c) when you create a data channel you pass channelPartitionName + "-DATA" to createMultiplexerChannel
d) when you connect a data channel you use channelPartitionName + "-DATA" to connect

> GroupMember passes null to Channel.connect()
> --------------------------------------------
>
>                 Key: JBMESSAGING-1244
>                 URL: http://jira.jboss.com/jira/browse/JBMESSAGING-1244
>             Project: JBoss Messaging
>          Issue Type: Bug
>          Components: Messaging Core
>    Affects Versions: 1.4.1.beta1
>            Reporter: Brian Stansberry
>         Assigned To: Jeff Mesnil
>             Fix For: 1.4.1.beta2
>
>
> When GroupMember connects a JGroups Channel, it passes null to Channel.connect(String).  It needs to pass the same value that it passes as the "id" param to ChannelFactory.createMultiplexerChannel(String stack_name, String id, boolean register_for_state_transfer, String substate_id), i.e.
> ${jboss.partition.name:DefaultPartition}-JMS-CTRL and ${jboss.partition.name:DefaultPartition}-JMS-DATA
> Passing null has worked solely due to an internal quirk in JGroups' MuxChannel implementation of the Channel interface.  If JGroups internally provides a shared transport JChannel instead of a MuxChannel, it will fail:
> 2008-02-28 17:43:06,098 ERROR [org.jboss.messaging.util.ExceptionUtil] org.jboss.messaging.core.jmx.MessagingPostOfficeService at 1a0d916 startService
> org.jgroups.ChannelException: failed to start protocol stack
> 	at org.jgroups.JChannel.startStack(JChannel.java:1440)
> 	at org.jgroups.JChannel.connect(JChannel.java:362)
> 	at org.jboss.messaging.core.impl.postoffice.GroupMember.start(GroupMember.java:142)
> 	at org.jboss.messaging.core.impl.postoffice.MessagingPostOffice.start(MessagingPostOffice.java:347)
> 	at org.jboss.messaging.core.jmx.MessagingPostOfficeService.startService(MessagingPostOfficeService.java:427)
>         ....
> Caused by: java.lang.NullPointerException
> 	at java.util.concurrent.ConcurrentHashMap.hash(ConcurrentHashMap.java:157)
> 	at java.util.concurrent.ConcurrentHashMap.containsKey(ConcurrentHashMap.java:745)
> 	at java.util.concurrent.ConcurrentHashMap$KeySet.contains(ConcurrentHashMap.java:1215)
> 	at org.jgroups.stack.Configurator.startProtocolStack(Configurator.java:85)
> 	at org.jgroups.stack.ProtocolStack.startStack(ProtocolStack.java:341)
> 	at org.jgroups.JChannel.startStack(JChannel.java:1437)
> 	... 59 more

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-jira mailing list