XMemcached 関連のコードで例外が発生します。誰かがこの期待を解決するのを手伝ってくれますか? アドバンスありがとうございました!
スレッド「Thread-9」の例外 java.lang.IllegalStateException: java.lang.ApplicationShutdownHooks.remove(ApplicationShutdownHooks.java:82) でシャットダウンが進行中です。 google.code.yanf4j.core.impl.AbstractController.stop(AbstractController.java:476) で net.rubyeye.xmemcached.XMemcachedClient.shutdown(XMemcachedClient.java:2482) で net.rubyeye.xmemcached.XMemcachedClient$1.run(XMemcachedClient) .java:650) ... もっと見る
MemcachedClient client = LowCardinalityMemcachedClientSingleton.getPrimaryClient();
try {
if(client.isShutdown() != true){
client.shutdown();
} else{
logger.debug("client already shutdown");
}
} catch (IOException e) {
logger.debug("Shutdown MemcachedClient fail", e);
}
long startTime = System.currentTimeMillis();
long total = 0;
logger.debug("about to run wait loop");
while(client.isShutdown() == false ||
total < 4000){
long stopTime = System.currentTimeMillis();
total = stopTime - startTime;
if(total > 12000){
logger.debug("breaking because waiting more than 12 seconds");
break;
}
}
logger.debug("exiting");
System.exit(0);
}