jboss 英飞凌-ISPN 000476:等待请求响应时超时

dfuffjeb  于 2022-11-23  发布在  其他
关注(0)|答案(1)|浏览(212)

我正在使用infinispan 7.2.5JBoss 7.2服务器上创建一个CacheServiceSingleton,在通信过程中遇到超时错误。我尝试将超时从默认值增加到35000毫秒,但没有任何帮助。我的配置中是否有什么突出的地方可能导致这些错误?

错误

javax.ejb.EJBTransactionRolledbackException: ISPN000476: Timed out waiting for responses for request 387 from devserver-44351
.....
Caused by: org.infinispan.util.concurrent.TimeoutException: ISPN000476: Timed out waiting for responses for request 387 from devserver-44351

启动代码

@PostConstruct
        void start() {
            logger.info("Starting cache service...");
            GlobalConfiguration gc = new GlobalConfigurationBuilder().transport().defaultTransport()
                    .globalJmxStatistics().allowDuplicateDomains(true).cacheManagerName("Cache").build();
            Configuration config = new ConfigurationBuilder().clustering().cacheMode(CacheMode.REPL_SYNC).sync().replTimeout(35000).build();
    
            cacheManager = new DefaultCacheManager(gc);
            cacheManager.defineConfiguration("times", config);
    
            lastGetTimesCache = cacheManager.getCache("times");
            logger.info("Cache service started!");
        }
yzuktlbb

yzuktlbb1#

添加jgroups配置解决了此问题

@PostConstruct
        void start() {
            logger.info("Starting cache service...");
            GlobalConfiguration gc = new GlobalConfigurationBuilder().transport().defaultTransport()
           .addProperty("configurationFile", "infinispan-jgroups.xml").globalJmxStatistics().allowDuplicateDomains(true).cacheManagerName("Cache").build();
            Configuration config = new ConfigurationBuilder().clustering().cacheMode(CacheMode.REPL_SYNC).sync().replTimeout(35000).build();
    
            cacheManager = new DefaultCacheManager(gc);
            cacheManager.defineConfiguration("times", config);
    
            lastGetTimesCache = cacheManager.getCache("times");
            logger.info("Cache service started!");
        }

相关问题