[ 
https://issues.apache.org/jira/browse/IGNITE-7759?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16372541#comment-16372541
 ] 

Roman Guseinov commented on IGNITE-7759:
----------------------------------------

Hi Ruchir,

 

Sure. No prob.

 

Best Regards,

Roman

> Logger does not print sockTimeout and ackTimeout default values for 
> TcpDiscoverySpi
> -----------------------------------------------------------------------------------
>
>                 Key: IGNITE-7759
>                 URL: https://issues.apache.org/jira/browse/IGNITE-7759
>             Project: Ignite
>          Issue Type: Bug
>    Affects Versions: 1.9, 2.1, 2.3
>            Reporter: Roman Guseinov
>            Priority: Minor
>              Labels: newbie
>
> Logger does not print sockTimeout and ackTimeout default values for 
> TcpDiscoverySpi
> Before starting TcpDiscoverySpi logger prints the following message (debug 
> mode is enabled):
> {code:java}
> [main][GridDiscoveryManager] Starting SPI: TcpDiscoverySpi [addrRslvr=null, 
> sockTimeout=0, ackTimeout=0, marsh=JdkMarshaller 
> [clsFilter=org.apache.ignite.internal.IgniteKernal$5@402e37bc], reconCnt=10, 
> reconDelay=2000, maxAckTimeout=600000, forceSrvMode=false, 
> clientReconnectDisabled=false]
> {code}
> Note, that sockTimeout=0 and ackTimeout=0. Default values initializing 
> happens after TcpDiscoverySpi.spiStart is called:
> {code:java}
> public class TcpDiscoverySpi extends IgniteSpiAdapter implements DiscoverySpi 
> {
>     /** Node attribute that is mapped to node's external addresses (value is 
> <tt>disc.tcp.ext-addrs</tt>). */
>     /** {@inheritDoc} */
>     @Override public void spiStart(@Nullable String igniteInstanceName) 
> throws IgniteSpiException {
>         initializeImpl();
>     }
>     /**
>      *
>      */
>     private void initializeImpl() {
>         if (impl != null)
>             return;
>         initFailureDetectionTimeout();
>         if (!forceSrvMode && 
> (Boolean.TRUE.equals(ignite.configuration().isClientMode()))) {
>             if (ackTimeout == 0)
>                 ackTimeout = DFLT_ACK_TIMEOUT_CLIENT;
>             if (sockTimeout == 0)
>                 sockTimeout = DFLT_SOCK_TIMEOUT_CLIENT;
>             impl = new ClientImpl(this);
>             ctxInitLatch.countDown();
>         }
>         else {
>             if (ackTimeout == 0)
>                 ackTimeout = DFLT_ACK_TIMEOUT;
>             if (sockTimeout == 0)
>                 sockTimeout = DFLT_SOCK_TIMEOUT;
>             impl = new ServerImpl(this);
>         }
>      
>     }
> }
> {code}
> To avoid confusion I suggest printing default sockTimeout and ackTimeout if 
> they weren't changed like:
> {code:java}
> [main][GridDiscoveryManager] Starting SPI: TcpDiscoverySpi [addrRslvr=null, 
> sockTimeout=5000, ackTimeout=5000, marsh=JdkMarshaller 
> [clsFilter=org.apache.ignite.internal.IgniteKernal$5@402e37bc], reconCnt=10, 
> reconDelay=2000, maxAckTimeout=600000, forceSrvMode=false, 
> clientReconnectDisabled=false]
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to