You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by VeenaMithare <v....@cmcmarkets.com> on 2020/10/01 17:04:59 UTC

Re: 2.8.1 : EVT_NODE_RECONNECTED, EVT_NODE_SEGMENTED on the client side

I rechecked this. My cluster setup is : 
servers : 3
client : 1

Bring down all nodes in the cluster for about 2 mins (
failuredetectiontimeout is 10 seconds ). The client receives
EVT_NODE_RECONNECTED and does not receive EVT_NODE_SEGMENTED.



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: 2.8.1 : EVT_NODE_RECONNECTED, EVT_NODE_SEGMENTED on the client side

Posted by VeenaMithare <v....@cmcmarkets.com>.
Hi Anton,

Thank you for the reply .

>>I can confirm that there is no SEGMENTED event thrown on 2.8.1.

I guess you meant that there is no SEGMENTED event thrown  in 2.8.1 client 
when the servers are brought down and started again. Because SEGMENTED event
could be thrown in 2.8.1 in other scenarios as well I guess, like a long GC
pause .

I have captured the logs for 2.7.6 client , where it receives a SEGMENTED
event. On closer look, it looks like the client's attempt to reconnect
failed in this case with 'Authentication Failure' and this has caused the
SEGMENTED event. 

Check this part of the log in the attached log : 
2020-10-08 09:59:33,327
[tcp-client-disco-msg-worker-#4%ProjectClient-null-igniteclient-SINGLE%]
ERROR
com.company.projectname.project.common.plugin.discoveryspi.CustomTcpDiscoverySpi
[] - Failed to reconnect, segment local node.
org.apache.ignite.spi.IgniteSpiException: Authentication failed
	at
org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi.checkFailedError(TcpDiscoverySpi.java:1946)
~[ignite-core-2.7.6.jar:2.7.6]
	at
org.apache.ignite.spi.discovery.tcp.ClientImpl$MessageWorker.body(ClientImpl.java:1888)
~[ignite-core-2.7.6.jar:2.7.6]
	at
org.apache.ignite.internal.util.worker.GridWorker.run(GridWorker.java:120)
~[ignite-core-2.7.6.jar:2.7.6]
	at
org.apache.ignite.spi.discovery.tcp.ClientImpl$1.body(ClientImpl.java:304)
~[ignite-core-2.7.6.jar:2.7.6]
	at org.apache.ignite.spi.IgniteSpiThread.run(IgniteSpiThread.java:62)
~[ignite-core-2.7.6.jar:2.7.6]
2020-10-08 09:59:33,328
[tcp-client-disco-msg-worker-#4%ProjectClient-null-igniteclient-SINGLE%]
DEBUG 

In 2.8.1, we have changed the security plugin , hence looks like the client
is able to reconnect successfully. 

In terms of the client, do we need to have the below 2 EVENT handlers? :
1. EVT_NODE_SEGMENTED - to restart the node and deploy and continuous
queries if needed.
2. EVT_CLIENT_NODE_RECONNECTED - to just deploy the continuous queries ( no
restart of node needed, since the node is already connected )

2.txt <http://apache-ignite-users.70518.x6.nabble.com/file/t2757/2.txt>  


regards,
Veena






--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: 2.8.1 : EVT_NODE_RECONNECTED, EVT_NODE_SEGMENTED on the client side

Posted by VeenaMithare <v....@cmcmarkets.com>.
Thanks Ilya,

>>I don't think so. Node can reconnect to a *different* cluster, or it may
be disconnected for a while and return to the same cluster. For client node,
segmented/disconnected difference is not relevant. Neither it is for server
node, in fact.

In  that case, we will have the same handler for segmented and reconnected
events. The handler will restart ignite and deploy any continuous queries as
needed.
Thank you for this guidance.

Does the server or the client need to have a handler for any other 'cluster
specific' events ?



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: 2.8.1 : EVT_NODE_RECONNECTED, EVT_NODE_SEGMENTED on the client side

Posted by Ilya Kasnacheev <il...@gmail.com>.
Hello!

You can just set clientReconnectEnabled to false. Then, if it is out of
topology, just start a new one to make sure you have a fresh start.

Not sure about other events. Maybe handle ACTIVATED/DEACTIVATED?

Regards,
-- 
Ilya Kasnacheev


вт, 13 окт. 2020 г. в 14:49, VeenaMithare <v....@cmcmarkets.com>:

> Thanks Ilya,
>
> >>I don't think so. Node can reconnect to a *different* cluster, or it may
> be disconnected for a while and return to the same cluster. For client
> node,
> segmented/disconnected difference is not relevant. Neither it is for server
> node, in fact.
>
> In  that case, we will have the same handler for segmented and reconnected
> events. The handler will restart ignite and deploy any continuous queries
> as
> needed.
> Thank you for this guidance.
>
> Does the server or the client need to have a handler for any other 'cluster
> specific' events ?
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>

Re: 2.8.1 : EVT_NODE_RECONNECTED, EVT_NODE_SEGMENTED on the client side

Posted by VeenaMithare <v....@cmcmarkets.com>.
Thanks Ilya,

>>I don't think so. Node can reconnect to a *different* cluster, or it may
be disconnected for a while and return to the same cluster. For client node,
segmented/disconnected difference is not relevant. Neither it is for server
node, in fact.

In  that case, we will have the same handler for segmented and reconnected
events. The handler will restart ignite and deploy any continuous queries as
needed.
Thank you for this guidance.

Does the server or the client need to have a handler for any other 'cluster
specific' events ?



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: 2.8.1 : EVT_NODE_RECONNECTED, EVT_NODE_SEGMENTED on the client side

Posted by Ilya Kasnacheev <il...@gmail.com>.
Hello!

I don't think so. Node can reconnect to a *different* cluster, or it may be
disconnected for a while and return to the same cluster. For client node,
segmented/disconnected difference is not relevant. Neither it is for server
node, in fact.

Regards,
-- 
Ilya Kasnacheev


вт, 13 окт. 2020 г. в 10:18, VeenaMithare <v....@cmcmarkets.com>:

> Hi Team,
>
>
> In terms of the client, do we need to have the below 2 EVENT handlers? :
> 1. EVT_NODE_SEGMENTED - to restart the node and deploy and continuous
> queries if needed.
> 2. EVT_CLIENT_NODE_RECONNECTED - to just deploy the continuous queries ( no
> restart of ignite needed, since the node is already connected )
>
> regards,
> Veena.
>
>
>
> --
> Sent from: http://apache-ignite-users.70518.x6.nabble.com/
>

Re: 2.8.1 : EVT_NODE_RECONNECTED, EVT_NODE_SEGMENTED on the client side

Posted by VeenaMithare <v....@cmcmarkets.com>.
Hi Team,


In terms of the client, do we need to have the below 2 EVENT handlers? :
1. EVT_NODE_SEGMENTED - to restart the node and deploy and continuous
queries if needed.
2. EVT_CLIENT_NODE_RECONNECTED - to just deploy the continuous queries ( no
restart of ignite needed, since the node is already connected )

regards,
Veena.



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: 2.8.1 : EVT_NODE_RECONNECTED, EVT_NODE_SEGMENTED on the client side

Posted by VeenaMithare <v....@cmcmarkets.com>.
Hi Anton,

Thank you for the reply .

>>I can confirm that there is no SEGMENTED event thrown on 2.8.1.

I guess you meant that there is no SEGMENTED event thrown  in 2.8.1 client 
when the servers are brought down and started again. Because SEGMENTED event
could be thrown in 2.8.1 in other scenarios as well I guess, like a long GC
pause .

I have captured the logs for 2.7.6 client , where it receives a SEGMENTED
event. On closer look, it looks like the client's attempt to reconnect
failed in this case with 'Authentication Failure' and this has caused the
SEGMENTED event. 

Check this part of the log in the attached log : 
2020-10-08 09:59:33,327
[tcp-client-disco-msg-worker-#4%ProjectClient-null-igniteclient-SINGLE%]
ERROR
com.company.projectname.project.common.plugin.discoveryspi.CustomTcpDiscoverySpi
[] - Failed to reconnect, segment local node.
org.apache.ignite.spi.IgniteSpiException: Authentication failed
	at
org.apache.ignite.spi.discovery.tcp.TcpDiscoverySpi.checkFailedError(TcpDiscoverySpi.java:1946)
~[ignite-core-2.7.6.jar:2.7.6]
	at
org.apache.ignite.spi.discovery.tcp.ClientImpl$MessageWorker.body(ClientImpl.java:1888)
~[ignite-core-2.7.6.jar:2.7.6]
	at
org.apache.ignite.internal.util.worker.GridWorker.run(GridWorker.java:120)
~[ignite-core-2.7.6.jar:2.7.6]
	at
org.apache.ignite.spi.discovery.tcp.ClientImpl$1.body(ClientImpl.java:304)
~[ignite-core-2.7.6.jar:2.7.6]
	at org.apache.ignite.spi.IgniteSpiThread.run(IgniteSpiThread.java:62)
~[ignite-core-2.7.6.jar:2.7.6]
2020-10-08 09:59:33,328
[tcp-client-disco-msg-worker-#4%ProjectClient-null-igniteclient-SINGLE%]
DEBUG 

In 2.8.1, we have changed the security plugin , hence looks like the client
is able to reconnect successfully. 

In terms of the client, do we need to have the below 2 EVENT handlers? :
1. EVT_NODE_SEGMENTED - to restart the node and deploy and continuous
queries if needed.
2. EVT_CLIENT_NODE_RECONNECTED - to just deploy the continuous queries ( no
restart of node needed, since the node is already connected )

SegmentedClientLogs.txt
<http://apache-ignite-users.70518.x6.nabble.com/file/t2757/SegmentedClientLogs.txt>  

regards,
Veena






--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: 2.8.1 : EVT_NODE_RECONNECTED, EVT_NODE_SEGMENTED on the client side

Posted by akurbanov <an...@gmail.com>.
Hi Veena, 

I can confirm that there is no SEGMENTED event thrown on 2.8.1.

I cannot reproduce catching the SEGMENTED event on 2.7.6. Could you help to
reproduce the behaviour or share the log where this event might be noticed?

Best regards,
Anton



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: 2.8.1 : EVT_NODE_RECONNECTED, EVT_NODE_SEGMENTED on the client side

Posted by VeenaMithare <v....@cmcmarkets.com>.
Hi ,

Kindly awaiting a reply on this ,

regards,
Veena



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/