[jboss-jira] [JBoss JIRA] Updated: (JGRP-1276) JGroups ignores my custom SocketFactory

Bela Ban (JIRA) jira-events at lists.jboss.org
Fri Jan 21 11:18:49 EST 2011


     [ https://issues.jboss.org/browse/JGRP-1276?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bela Ban updated JGRP-1276:
---------------------------

    Fix Version/s: 2.12


> JGroups ignores my custom SocketFactory
> ---------------------------------------
>
>                 Key: JGRP-1276
>                 URL: https://issues.jboss.org/browse/JGRP-1276
>             Project: JGroups
>          Issue Type: Bug
>    Affects Versions: 2.10
>         Environment: All
>            Reporter: Adrian Tarau
>            Assignee: Bela Ban
>             Fix For: 2.12
>
>
> I was trying to replace the default socket factory with my own socket factory so I can decide if MulticaseSocket is created with InetSocketAddress or to use just the port(to experiment this "Invalid argument") and it doesn't use my socket factory.
> Looking in the code, the way(the call order) how the socket factory is forwarded to the protocols is wrong(I think) because the protocols are started with the default stack instead of my stack.
> prot_stack.getTopProtocol().setSocketFactory(socket_factory) should be called before the stack is started and not after.
> private void startStack(String cluster_name) throws ChannelException {
> .....
>         try {
>             prot_stack.startStack(cluster_name, local_addr); // calls start() in all protocols, from top to bottom
>         }
>         catch(Throwable e) {
>             throw new ChannelException("failed to start protocol stack", e);
>         }
>         if(socket_factory != null) {
>             prot_stack.getTopProtocol().setSocketFactory(socket_factory);
>         }
> ....
> }

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jboss-jira mailing list