Re: [jgroups-users] Using JGroups with Ehcache+Hibernate not working

Questions/problems related to using JGroups <[email protected]> Tue, 26 Mar 2019 16:55:36 +0000
Newsgroups gmane.comp.java.javagroups.general
Message-ID <mailman.16180.1553635706.1518.javagroups-users@lists.sourceforge.net>
Thanks a lot. "-Djava.net.preferIPv4Stack=true"  worked :-)

Regards,
Ranjeeta

-----Original Message-----
From: Questions/problems related to using JGroups <[email protected]> 
Sent: Tuesday, March 26, 2019 3:28 PM
To: [email protected]
Subject: Re: [jgroups-users] Using JGroups with Ehcache+Hibernate not working

I'm afraid I don't know how ehcache replication works, but the config looks really old, and JGroups version 3.0.x _is_ definitely too old! 
Isn't there a newer version of ehcache-jgroupsreplication-1.7.jar?

One thing to try is to force IPv4 addresses by setting -Djava.net.preferIPv4Stack=true.



On 26.03.19 09:54, Questions/problems related to using JGroups wrote:
> Hi,
> 
> We have multiple Java processes running on a single host that talk to a
> single database using Hibernate. Later on the processes will run from
> different hosts but for now everything runs on the same machine.
> To improve our applications performance we decided to use Hibernate Second
> Level Caching with Ehcache. Till here it works fine. But since we have
> different java processes we need JGroups to sync the Ehcache in each
> process. This is not working.
> 
> Environment: Linux Red Hat Enterprise Linux Server release 6.8 (Santiago)
> ehcache-2.10.5.jar
> ehcache-jgroupsreplication-1.7.jar
> hibernate-ehcache-4.3.11.Final.jar
> jgroups-3.0.16.Final.jar
> openjdk version "1.8.0_141"
> 
> Attached is the ehcache.xml that has the configuration for JGroups
> ehcache.xml <https://urldefense.proofpoint.com/v2/url?u=http-3A__jgroups.1086181.n5.nabble.com_file_t1834_ehcache.xml&d=DwICAg&c=BFpWQw8bsuKpl1SgiZH64Q&r=VK46Dhj8pF3c2pox3j1TyIsBWKLlVVyZyqWmoD0LhXM&m=vi7m8BEsUP8uOri7e3ztztXWUzMUBVg3tP0nzUKge8s&s=emK3k4NHmdVxJo6z_S2VJrH8LCYf9oOIZ8LlcUWmbRQ&e=>
> 
> On starting the java processes we are able to see the EH_CACHE and other
> related threads in JConsole, so I assume it is getting all the jars etc.
> JConsole.PNG <https://urldefense.proofpoint.com/v2/url?u=http-3A__jgroups.1086181.n5.nabble.com_file_t1834_JConsole.PNG&d=DwICAg&c=BFpWQw8bsuKpl1SgiZH64Q&r=VK46Dhj8pF3c2pox3j1TyIsBWKLlVVyZyqWmoD0LhXM&m=vi7m8BEsUP8uOri7e3ztztXWUzMUBVg3tP0nzUKge8s&s=tJvf1BCeTPDMXBx6jYbz122z8InO4xFSn4DYayHFluE&e=>
> 
> We are also able to see the UDP traffic. This means the packets are being
> sent but probably not received.
> #tcpdump -v udp port 45566
> tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size 65535
> bytes
> 20:47:51.459913 IP6 (class 0x08, hlim 32, next-header UDP (17) payload
> length: 85) fe80::5054:ff:fe63:b8dd.45566 > ff0e::e70c:1584.45566: [udp sum
> ok] UDP, length 77
> 
> Can someone please confirm if the configurations in the Ehcache.xml are
> correct or not?
> What multicast IP should we be using? We are aware of the reserved IPs and
> not used from that list.
> Apart from this do we have to do any other configurations for the network
> etc.
> I do not have much networking knowledge and new to JGroups as well.
> 
> Thanks!
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> --
> Sent from: https://urldefense.proofpoint.com/v2/url?u=http-3A__jgroups.1086181.n5.nabble.com_JGroups-2DGeneral-2Df3.html&d=DwICAg&c=BFpWQw8bsuKpl1SgiZH64Q&r=VK46Dhj8pF3c2pox3j1TyIsBWKLlVVyZyqWmoD0LhXM&m=vi7m8BEsUP8uOri7e3ztztXWUzMUBVg3tP0nzUKge8s&s=tF-xxD4e-VFBfq_siE1LcNEypCMIIrkUH3Xg3t9ve-w&e=
> 
> 
> _______________________________________________
> javagroups-users mailing list
> [email protected]
> https://urldefense.proofpoint.com/v2/url?u=https-3A__lists.sourceforge.net_lists_listinfo_javagroups-2Dusers&d=DwICAg&c=BFpWQw8bsuKpl1SgiZH64Q&r=VK46Dhj8pF3c2pox3j1TyIsBWKLlVVyZyqWmoD0LhXM&m=vi7m8BEsUP8uOri7e3ztztXWUzMUBVg3tP0nzUKge8s&s=XvHi6EmXAwer0joXYq2uym967obWSvkNRg1NxKYm_bw&e=
> 

-- 
Bela Ban | https://urldefense.proofpoint.com/v2/url?u=http-3A__www.jgroups.org&d=DwICAg&c=BFpWQw8bsuKpl1SgiZH64Q&r=VK46Dhj8pF3c2pox3j1TyIsBWKLlVVyZyqWmoD0LhXM&m=vi7m8BEsUP8uOri7e3ztztXWUzMUBVg3tP0nzUKge8s&s=aKBbDAaD5qzTOEybdJ9TOWANSX8zfGD5aGLVEUCiED0&e=



_______________________________________________
javagroups-users mailing list
[email protected]
https://urldefense.proofpoint.com/v2/url?u=https-3A__lists.sourceforge.net_lists_listinfo_javagroups-2Dusers&d=DwICAg&c=BFpWQw8bsuKpl1SgiZH64Q&r=VK46Dhj8pF3c2pox3j1TyIsBWKLlVVyZyqWmoD0LhXM&m=vi7m8BEsUP8uOri7e3ztztXWUzMUBVg3tP0nzUKge8s&s=XvHi6EmXAwer0joXYq2uym967obWSvkNRg1NxKYm_bw&e=