You can extend the stopnode handler and stop Java process when
stopnodehandler is called by ignite.
We did similar thing in our project

On Wed, Nov 27, 2019, 17:00 Akash Shinde <akashshi...@gmail.com> wrote:

> Hi ,
>
> I have started four server nodes. One of the node got terminated
> unexpectedly giving following error. Before terminating the JVM the node
> was segmented.
>
> 1) Does ignite always treat node segmentation as "Critical system error"
> and use "StopNodeOrHaltFailureHandler" to take required action which
> "Teminate Node" in this case?
>
> 2) Are there any other reasons for   "Critical system error detected"
> message?
>
> I have not set the SegmentationPolicy  explicitly.  AFAIK ignite does not
> provide SegmentationResolver and SegmentationPolicy out of box.
>
> 3) Do I need to implement SegmentationResolver and set the
> SegmenetationPolicy to "STOP" if I want to stop the JVM if the node is
> segmented?
>
> 4) I am starting Ignite in embedded mode. When a node is segmented  I want
> restart the JVM. I
> Is there any way to do this? (I am not using ignite.sh/ignite.bat) to
> start the ignite.
>
> Please find attached logs.
>
> Exception:
>
>
>
>
>
>
>
>
>
>
>
>
> *2019-11-27 08:30:46,992 9321188 [disco-event-worker-#61%springDataNode%]
> WARN  o.a.i.i.m.d.GridDiscoveryManager - Local node SEGMENTED:
> TcpDiscoveryNode [id=b4fce076-cc7a-47ee-98fd-31e1d610b5de,
> addrs=[10.45.65.97, 127.0.0.1], sockAddrs=[/10.45.65.97:47500
> <http://10.45.65.97:47500>, /127.0.0.1:47500 <http://127.0.0.1:47500>],
> discPort=47500, order=1, intOrder=1, lastExchangeTime=1574843446983,
> loc=true, ver=2.6.0#20180710-sha1:669feacc, isClient=false]2019-11-27
> 08:30:46,992 9321188 [disco-event-worker-#61%springDataNode%] WARN
>  o.a.i.i.m.d.GridDiscoveryManager - Local node SEGMENTED: TcpDiscoveryNode
> [id=b4fce076-cc7a-47ee-98fd-31e1d610b5de, addrs=[10.45.65.97, 127.0.0.1],
> sockAddrs=[/10.45.65.97:47500 <http://10.45.65.97:47500>, /127.0.0.1:47500
> <http://127.0.0.1:47500>], discPort=47500, order=1, intOrder=1,
> lastExchangeTime=1574843446983, loc=true, ver=2.6.0#20180710-sha1:669feacc,
> isClient=false]2019-11-27 08:30:46,994 9321190
> [tcp-disco-srvr-#3%springDataNode%] ERROR  - Critical system error
> detected. Will be handled accordingly to configured handler [hnd=class
> o.a.i.failure.StopNodeOrHaltFailureHandler, failureCtx=FailureContext
> [type=SYSTEM_WORKER_TERMINATION, err=java.lang.IllegalStateException:
> Thread tcp-disco-srvr-#3%springDataNode% is terminated
> unexpectedly.]]java.lang.IllegalStateException: Thread
> tcp-disco-srvr-#3%springDataNode% is terminated unexpectedly.        at
> org.apache.ignite.spi.discovery.tcp.ServerImpl$TcpServer.body(ServerImpl.java:5686)
>       at
> org.apache.ignite.spi.IgniteSpiThread.run(IgniteSpiThread.java:62)2019-11-27
> 08:30:46,994 9321190 [tcp-disco-srvr-#3%springDataNode%] ERROR  - Critical
> system error detected. Will be handled accordingly to configured handler
> [hnd=class o.a.i.failure.StopNodeOrHaltFailureHandler,
> failureCtx=FailureContext [type=SYSTEM_WORKER_TERMINATION,
> err=java.lang.IllegalStateException: Thread
> tcp-disco-srvr-#3%springDataNode% is terminated
> unexpectedly.]]java.lang.IllegalStateException: Thread
> tcp-disco-srvr-#3%springDataNode% is terminated unexpectedly.        at
> org.apache.ignite.spi.discovery.tcp.ServerImpl$TcpServer.body(ServerImpl.java:5686)
>       at
> org.apache.ignite.spi.IgniteSpiThread.run(IgniteSpiThread.java:62)2019-11-27
> 08:30:46,995 9321191 [tcp-disco-srvr-#3%springDataNode%] ERROR  - JVM will
> be halted immediately due to the failure: [failureCtx=FailureContext
> [type=SYSTEM_WORKER_TERMINATION, err=java.lang.IllegalStateException:
> Thread tcp-disco-srvr-#3%springDataNode% is terminated
> unexpectedly.]]2019-11-27 08:30:46,995 9321191
> [tcp-disco-srvr-#3%springDataNode%] ERROR  - JVM will be halted immediately
> due to the failure: [failureCtx=FailureContext
> [type=SYSTEM_WORKER_TERMINATION, err=java.lang.IllegalStateException:
> Thread tcp-disco-srvr-#3%springDataNode% is terminated unexpectedly.]]*
>
>
>
>
>
>
>
>
>

Reply via email to