[jboss-jira] [JBoss JIRA] (JGRP-1862) NPE during FIND_MBRS when using shared transport

Bela Ban (JIRA) issues at jboss.org
Thu Jul 24 04:21:30 EDT 2014


    [ https://issues.jboss.org/browse/JGRP-1862?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12987578#comment-12987578 ] 

Bela Ban commented on JGRP-1862:
--------------------------------

Caused by the code passing up the FIND_MBRS event always returning null. Changed this to ensure a non-null Responses object is returned.
Paul: I thought WildFly clustering switched from shared transports to {{FORK}} ?

> NPE during FIND_MBRS when using shared transport
> ------------------------------------------------
>
>                 Key: JGRP-1862
>                 URL: https://issues.jboss.org/browse/JGRP-1862
>             Project: JGroups
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>    Affects Versions: 3.5
>            Reporter: Paul Ferraro
>            Assignee: Bela Ban
>            Priority: Blocker
>             Fix For: 3.5
>
>
> The following code within org.jgroups.protocols.TP.sendToSingleMember(...) throws an NPE if the transport is shared:
> {code}
>     Responses responses=(Responses)up(new Event(Event.FIND_MBRS, Arrays.asList(dest)));
>     try {
>         for(PingData data : responses) {
>             if(data.getAddress() != null && data.getAddress().equals(dest)) {
>                 if((physical_dest=data.getPhysicalAddr()) != null) {
>                     sendUnicast(physical_dest, buf, offset, length);
>                     return;
>                 }
>             }
>         }
>     }
>     finally {
>         responses.done();
>     }
> {code}
> This is because up(Event) always returns null when using a shared transport.
> The same issue affects org.jgroups.protocols.TP.fetchPhysicalAddrs(...):
> {code}
>     if(!missing.isEmpty()) {
>         Responses rsps=(Responses)up(new Event(Event.FIND_MBRS, missing));
>         rsps.done();
>     }
> {code}



--
This message was sent by Atlassian JIRA
(v6.2.6#6264)


More information about the jboss-jira mailing list