访问Ignite缓存进行查询时,出现“ 缓存已关闭”异常。我正在做的很简单,
asm{}
初始化此代码后,在我代码的其他位置调用CacheConfiguration cfg = new CacheConfiguration();
cacheConfiguration.setCacheMode(CacheMode.REPLICATED);
cacheConfiguration.setAtomicityMode(CacheAtomicityMode.TRANSACTIONAL_SNAPSHOT); cacheConfiguration.setWriteSynchronizationMode(CacheWriteSynchronizationMode.PRIMARY_SYNC);
IgniteCache cache = ignite.getOrCreateCache(cfg);
;但这引发了异常。
缓存变量是某个类的对象的成员。为什么直到手动关闭缓存后才能保持打开状态。
我什么都没关上
答案 0 :(得分:1)
通常会发生这种情况,因为您没有在代码中的任何地方调用FFI::NotFoundError: Function 'getdtablesize' not found in [libc.so]
/data/data/com.termux/files/home/Projects/myapp/.bundle/ruby/2.7.0/gems/ffi-1.11.3/lib/ffi/library.rb:273:in `attach_function'
/data/data/com.termux/files/home/Projects/myapp/.bundle/ruby/2.7.0/gems/ethon-0.12.0/lib/ethon/libc.rb:16:in `<module:Libc>'
/data/data/com.termux/files/home/Projects/myapp/.bundle/ruby/2.7.0/gems/ethon-0.12.0/lib/ethon/libc.rb:6:in `<module:Ethon>'
/data/data/com.termux/files/home/Projects/myapp/.bundle/ruby/2.7.0/gems/ethon-0.12.0/lib/ethon/libc.rb:1:in `<main>'
/data/data/com.termux/files/home/Projects/myapp/.bundle/ruby/2.7.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require'
/data/data/com.termux/files/home/Projects/myapp/.bundle/ruby/2.7.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi'
/data/data/com.termux/files/home/Projects/myapp/.bundle/ruby/2.7.0/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'```
或。.close()
时,客户端断开连接,服务器关闭或客户端重新加入新ID。