[ https://issues.apache.org/jira/browse/IGNITE-4939?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16243634#comment-16243634 ]
Denis Mekhanikov commented on IGNITE-4939: ------------------------------------------ Here is a reproducer for Ignite 2.3: {code} public class CacheNotConfiguredExample { TcpDiscoveryIpFinder ipFinder = new TcpDiscoveryVmIpFinder(true); public static void main(String[] args) { new CacheNotConfiguredExample().doMain(); } void doMain() { new Thread(this::startServer).start(); new Thread(this::startClient).start(); } Ignite startClient() { IgniteConfiguration igniteCfg = igniteConfiguration(); igniteCfg.setIgniteInstanceName("Client Node"); igniteCfg.setClientMode(true); return Ignition.start(igniteCfg); } Ignite startServer() { IgniteConfiguration igniteCfg = igniteConfiguration(); igniteCfg.setIgniteInstanceName("Server Node"); igniteCfg.setServiceConfiguration(serviceConfiguration()); igniteCfg.setClientMode(false); return Ignition.start(igniteCfg); } IgniteConfiguration igniteConfiguration() { IgniteConfiguration cfg = new IgniteConfiguration(); TcpDiscoverySpi spi = new TcpDiscoverySpi(); spi.setIpFinder(ipFinder); cfg.setDiscoverySpi(spi); return cfg; } ServiceConfiguration serviceConfiguration() { ServiceConfiguration svcCfg = new ServiceConfiguration(); svcCfg.setName("service"); svcCfg.setTotalCount(1); svcCfg.setService(new SimpleMapServiceImpl<Integer, String>()); return svcCfg; } } {code} There is a race, so the exception may appear not every time. > Receive event before cache initialized > -------------------------------------- > > Key: IGNITE-4939 > URL: https://issues.apache.org/jira/browse/IGNITE-4939 > Project: Ignite > Issue Type: Bug > Components: cache > Affects Versions: 1.9 > Reporter: Nikolay Tikhonov > Assignee: Evgenii Zhuravlev > Fix For: 2.1 > > > Receive event before cache initialized that leads to the following: > {noformat} > Exception in thread "sys-#755%Default%" java.lang.IllegalArgumentException: > Cache is not configured: ignite-sys-cache > at > org.apache.ignite.internal.processors.cache.GridCacheProcessor.jcache(GridCacheProcessor.java:3343) > at > org.apache.ignite.internal.processors.cache.query.continuous.CacheContinuousQueryHandler.handleEvent(CacheContinuousQueryHandler.java:719) > at > org.apache.ignite.internal.processors.cache.query.continuous.CacheContinuousQueryHandler.notifyCallback0(CacheContinuousQueryHandler.java:691) > at > org.apache.ignite.internal.processors.cache.query.continuous.CacheContinuousQueryHandler.notifyCallback(CacheContinuousQueryHandler.java:650) > at > org.apache.ignite.internal.processors.continuous.GridContinuousProcessor.processNotification(GridContinuousProcessor.java:1086) > at > org.apache.ignite.internal.processors.continuous.GridContinuousProcessor.access$2000(GridContinuousProcessor.java:97) > at > org.apache.ignite.internal.processors.continuous.GridContinuousProcessor$8.onMessage(GridContinuousProcessor.java:741) > at > org.apache.ignite.internal.managers.communication.GridIoManager.invokeListener(GridIoManager.java:1082) > at > org.apache.ignite.internal.managers.communication.GridIoManager.access$1600(GridIoManager.java:102) > at > org.apache.ignite.internal.managers.communication.GridIoManager$GridCommunicationMessageSet.unwind(GridIoManager.java:2332) > at > org.apache.ignite.internal.managers.communication.GridIoManager.unwindMessageSet(GridIoManager.java:1042) > at > org.apache.ignite.internal.managers.communication.GridIoManager.access$1900(GridIoManager.java:102) > at > org.apache.ignite.internal.managers.communication.GridIoManager$6.run(GridIoManager.java:1011) > at > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) > at > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) > at java.lang.Thread.run(Thread.java:745) > {noformat} -- This message was sent by Atlassian JIRA (v6.4.14#64029)