-
1. Re: Infinispan data load into Remote Cache multiple node concurrently
rvansa Jun 27, 2017 4:50 AM (in response to abhishekdg1983)Just spawn a couple of threads (or use a threadpool) and write the data to the cache. Both RemoteCacheManager and RemoteCache are safe for concurrent access.
-
2. Re: Infinispan data load into Remote Cache multiple node concurrently
abhishekdg1983 Jun 27, 2017 6:21 AM (in response to rvansa)How can we connect to multiple port in Hotrod? And is there any example of
thread pool available for multiple port?
-
3. Re: Infinispan data load into Remote Cache multiple node concurrently
rvansa Jun 27, 2017 6:31 AM (in response to abhishekdg1983)The server handles connections from different destinations to single port. Just invoke RemoteCache.put() from different threads, the calls will proceed concurrently.
-
4. Re: Infinispan data load into Remote Cache multiple node concurrently
abhishekdg1983 Jun 27, 2017 6:45 AM (in response to rvansa)Cannot we add programmatically different port in this code from the client:
builder.addServer().host("127.0.0.1").port(11222).socketTimeout(1200000).security().authentication().enable().serverName("myhotrodserver").
saslMechanism("DIGEST-MD5").callbackHandler(new
MyCallBackHandler("myuser", "ApplicationRealm",
"qwer1234!".toCharArray())).marshaller(new ProtoStreamMarshaller());
cacheManager = new RemoteCacheManager(builder.build());
addressbookCache = cacheManager.getCache(cacheName);
if (addressbookCache == null) {
throw new RuntimeException("Cache '" + cacheName + "' not found.
Please make sure the server is properly configured");
}
-
5. Re: Infinispan data load into Remote Cache multiple node concurrently
rvansa Jun 27, 2017 7:12 AM (in response to abhishekdg1983)Ah, do I understand correctly that you want to store the same data in several *not clustered* servers? There's no support for that; the expected use case is that you have several servers clustered together, and you store the data into such cluster transparently. All the client needs is address of one of those servers, it can figure out other servers and decide on which node should be the data stored automatically.