ignite-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alexey Popov <tank2.a...@gmail.com>
Subject Re: Node failed to startup due to deadlock
Date Thu, 02 Nov 2017 16:22:25 GMT
Hi Rajeev,

All Ignite callbacks are processed in (=called from) internal Ignite thread
The generic rule here is to avoid direct Ignite calls from such callbacks.
So, it is better to do all your things in separate threads (use
ExecutorService for instance).
You should pass all work to your own threads and release internal Ignite
threads by returning from callbacks.

Sample code:

        final ExecutorService executorService =

        ignite.events().localListen(new IgnitePredicate<Event>() {
            @Override public boolean apply(Event event) {
                executorService.execute(new Runnable() {
                    public void run() {
                        // do all the job here
                        ignite.log().error("Event: " + event.name());
                return true;
        }, EventType.EVTS_DISCOVERY);

I checked your logs, there are deadlocks at Cache operations.


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

View raw message