Re: [jgroups-users] How to hijack a JGroups channel inside Infinispan ... (and get away with it !)

Questions/problems related to using JGroups <[email protected]> Wed, 15 Jan 2020 09:00:10 +0100
Newsgroups gmane.comp.java.javagroups.general
Message-ID <mailman.1958.1579075236.1535.javagroups-users@lists.sourceforge.net>
--===============5103686303414308639==
Content-Type: multipart/alternative; boundary="000000000000a3af6e059c2919b6"

--000000000000a3af6e059c2919b6
Content-Type: text/plain; charset="UTF-8"

I did reply yesterday but just realised my message was blocked.. "550
Blacklisted file extension detected". There must have been a rogue JVM
because now it seems to be working with the changes you suggested (hope
this is what you meant
https://github.com/johnou/orbit-infinispan/blob/master/src/main/java/com/sulake/proto/jgroups/JGroupsClusterPeer.java#L169
),
regardless I am happy to share the project I put together just in case
anyone else is interested! https://github.com/johnou/orbit-infinispan

On Tue, Jan 14, 2020 at 6:59 PM Questions/problems related to using JGroups
<[email protected]> wrote:

> A reproducer with a POM including the right deps would be good, so I can
> take a look
>
> On 14.01.20 15:45, Questions/problems related to using JGroups wrote:
> > Not missing any ctors, I am happy with JChannel(InputStream) it makes
> > more sense than URL.
> >
> > Infinispan 9.4.16 to 10.1.0.Final.
> >
> > I rewrote the bootstrap as you suggested but the fork channel is still
> > logging the same warn message.
> >
> > 2020-01-14T15:43:06,077 WARN  [jgroups-5,proxy-service-1-4894]
> > (org.jgroups.protocols.FORK) null: fork-channel for id=lead-hijacker not
> > found; discarding message []
> > 2020-01-14T15:43:15,416 WARN  [jgroups-11,proxy-service-1-4894]
> > (org.jgroups.protocols.FORK) null: fork-channel for id=lead-hijacker not
> > found; discarding message []
> > 2020-01-14T15:43:15,446 WARN  [jgroups-11,proxy-service-1-4894]
> > (org.jgroups.protocols.FORK) null: fork-channel for id=lead-hijacker not
> > found; discarding message []
> > 2020-01-14T15:43:15,466 WARN  [jgroups-11,proxy-service-1-4894]
> > (org.jgroups.protocols.FORK) null: fork-channel for id=lead-hijacker not
> > found; discarding message []
> > 2020-01-14T15:43:15,491 WARN  [jgroups-11,proxy-service-1-4894]
> > (org.jgroups.protocols.FORK) null: fork-channel for id=lead-hijacker not
> > found; discarding message []
> > 2020-01-14T15:43:15,512 WARN  [jgroups-11,proxy-service-1-4894]
> > (org.jgroups.protocols.FORK) null: fork-channel for id=lead-hijacker not
> > found; discarding message []
> > 2020-01-14T15:43:16,081 WARN  [jgroups-11,proxy-service-1-4894]
> > (org.jgroups.protocols.FORK) null: fork-channel for id=lead-hijacker not
> > found; discarding message []
> > 2020-01-14T15:43:26,079 WARN  [jgroups-16,proxy-service-1-4894]
> > (org.jgroups.protocols.FORK) null: fork-channel for id=lead-hijacker not
> > found; discarding message []
> > 2020-01-14T15:43:36,080 WARN  [jgroups-17,proxy-service-1-4894]
> > (org.jgroups.protocols.FORK) null: fork-channel for id=lead-hijacker not
> > found; discarding message []
> >
> > I will reserve some time later this afternoon to put together a small
> > reproducer.
> >
> > On Tue, Jan 14, 2020 at 1:17 PM Questions/problems related to using
> > JGroups <[email protected]
> > <mailto:[email protected]>> wrote:
> >
> >     Why do you create your own base channel? You should fetch the
> existing
> >     JChannel from Infinispan and create a ForkChannel over it.
> >     Which ctor are you missing? new JChannel(InputStream) still exists!
> >     Cheers,
> >
> >     On 13.01.20 16:37, Questions/problems related to using JGroups wrote:
> >      > Hey all,
> >      >
> >      > So I recently upgraded to Infinispan 10.1.0.Final and it came
> >     with a few
> >      > surprises with the JGroups update, a few of the constructors in
> >     JChannel
> >      > are no longer available - it was fast to replace this with
> >      > org.jgroups.conf.XmlConfigurator , however, the hijacked channel
> >     on the
> >      > other hand seems to be broken / non functional (see logs below)..
> >     before
> >      > digging into the Infinispan Jgroups bootstrap code too far I
> >     thought it
> >      > might be worth reaching out here just in case someone has already
> >     run
> >      > into this problem.
> >      >
> >      > 2020-01-13T16:11:15,444 WARN  [jgroups-6,space-service-1]
> >      > (org.jgroups.protocols.FORK) space-service-1: fork-channel for
> >      > id=lead-hijacker not found; discarding message []
> >      > 2020-01-13T16:11:15,466 WARN  [jgroups-6,space-service-1]
> >      > (org.jgroups.protocols.FORK) space-service-1: fork-channel for
> >      > id=lead-hijacker not found; discarding message []
> >      > 2020-01-13T16:11:15,490 WARN  [jgroups-6,space-service-1]
> >      > (org.jgroups.protocols.FORK) space-service-1: fork-channel for
> >      > id=lead-hijacker not found; discarding message []
> >      > 2020-01-13T16:11:15,512 WARN  [jgroups-6,space-service-1]
> >      > (org.jgroups.protocols.FORK) space-service-1: fork-channel for
> >      > id=lead-hijacker not found; discarding message []
> >      > 2020-01-13T16:11:15,917 WARN  [jgroups-6,space-service-1]
> >      > (org.jgroups.protocols.FORK) space-service-1: fork-channel for
> >      > id=lead-hijacker not found; discarding message []
> >      >
> >      > Cheers,
> >      >
> >      > --
> >      > Johno Crawford
> >      >
> >      >
> >      > _______________________________________________
> >      > javagroups-users mailing list
> >      > [email protected]
> >     <mailto:[email protected]>
> >      > https://lists.sourceforge.net/lists/listinfo/javagroups-users
> >      >
> >
> >     --
> >     Bela Ban | http://www.jgroups.org
> >
> >
> >
> >     _______________________________________________
> >     javagroups-users mailing list
> >     [email protected]
> >     <mailto:[email protected]>
> >     https://lists.sourceforge.net/lists/listinfo/javagroups-users
> >
> >
> >
> > --
> > Johno Crawford
> >
> >
> > _______________________________________________
> > javagroups-users mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/javagroups-users
> >
>
> --
> Bela Ban | http://www.jgroups.org
>
>
>
> _______________________________________________
> javagroups-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/javagroups-users
>


-- 
Johno Crawford

--000000000000a3af6e059c2919b6
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">I did reply yesterday but just realised my message was blo=
cked.. &quot;550 Blacklisted file extension detected&quot;. There must have=
 been a rogue JVM because now it seems to be working with the changes you s=
uggested (hope this is what you meant=C2=A0<a href=3D"https://github.com/jo=
hnou/orbit-infinispan/blob/master/src/main/java/com/sulake/proto/jgroups/JG=
roupsClusterPeer.java#L169">https://github.com/johnou/orbit-infinispan/blob=
/master/src/main/java/com/sulake/proto/jgroups/JGroupsClusterPeer.java#L169=
</a>=C2=A0), regardless I am happy to share the project I put together just=
 in case anyone else is interested!=C2=A0<a href=3D"https://github.com/john=
ou/orbit-infinispan">https://github.com/johnou/orbit-infinispan</a><br></di=
v><br><div class=3D"gmail_quote"><div dir=3D"ltr" class=3D"gmail_attr">On T=
ue, Jan 14, 2020 at 6:59 PM Questions/problems related to using JGroups &lt=
;<a href=3D"mailto:[email protected]">javagroups-users=
@lists.sourceforge.net</a>&gt; wrote:<br></div><blockquote class=3D"gmail_q=
uote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,2=
04);padding-left:1ex">A reproducer with a POM including the right deps woul=
d be good, so I can <br>
take a look<br>
<br>
On 14.01.20 15:45, Questions/problems related to using JGroups wrote:<br>
&gt; Not missing any ctors, I am happy with JChannel(InputStream) it makes =
<br>
&gt; more sense than URL.<br>
&gt; <br>
&gt; Infinispan 9.4.16 to=C2=A010.1.0.Final.<br>
&gt; <br>
&gt; I rewrote the bootstrap as you suggested but the fork channel is still=
 <br>
&gt; logging the same warn message.<br>
&gt; <br>
&gt; 2020-01-14T15:43:06,077 WARN =C2=A0[jgroups-5,proxy-service-1-4894] <b=
r>
&gt; (org.jgroups.protocols.FORK) null: fork-channel for id=3Dlead-hijacker=
 not <br>
&gt; found; discarding message []<br>
&gt; 2020-01-14T15:43:15,416 WARN =C2=A0[jgroups-11,proxy-service-1-4894] <=
br>
&gt; (org.jgroups.protocols.FORK) null: fork-channel for id=3Dlead-hijacker=
 not <br>
&gt; found; discarding message []<br>
&gt; 2020-01-14T15:43:15,446 WARN =C2=A0[jgroups-11,proxy-service-1-4894] <=
br>
&gt; (org.jgroups.protocols.FORK) null: fork-channel for id=3Dlead-hijacker=
 not <br>
&gt; found; discarding message []<br>
&gt; 2020-01-14T15:43:15,466 WARN =C2=A0[jgroups-11,proxy-service-1-4894] <=
br>
&gt; (org.jgroups.protocols.FORK) null: fork-channel for id=3Dlead-hijacker=
 not <br>
&gt; found; discarding message []<br>
&gt; 2020-01-14T15:43:15,491 WARN =C2=A0[jgroups-11,proxy-service-1-4894] <=
br>
&gt; (org.jgroups.protocols.FORK) null: fork-channel for id=3Dlead-hijacker=
 not <br>
&gt; found; discarding message []<br>
&gt; 2020-01-14T15:43:15,512 WARN =C2=A0[jgroups-11,proxy-service-1-4894] <=
br>
&gt; (org.jgroups.protocols.FORK) null: fork-channel for id=3Dlead-hijacker=
 not <br>
&gt; found; discarding message []<br>
&gt; 2020-01-14T15:43:16,081 WARN =C2=A0[jgroups-11,proxy-service-1-4894] <=
br>
&gt; (org.jgroups.protocols.FORK) null: fork-channel for id=3Dlead-hijacker=
 not <br>
&gt; found; discarding message []<br>
&gt; 2020-01-14T15:43:26,079 WARN =C2=A0[jgroups-16,proxy-service-1-4894] <=
br>
&gt; (org.jgroups.protocols.FORK) null: fork-channel for id=3Dlead-hijacker=
 not <br>
&gt; found; discarding message []<br>
&gt; 2020-01-14T15:43:36,080 WARN =C2=A0[jgroups-17,proxy-service-1-4894] <=
br>
&gt; (org.jgroups.protocols.FORK) null: fork-channel for id=3Dlead-hijacker=
 not <br>
&gt; found; discarding message []<br>
&gt; <br>
&gt; I will reserve some time later this afternoon to put together a small =
<br>
&gt; reproducer.<br>
&gt; <br>
&gt; On Tue, Jan 14, 2020 at 1:17 PM Questions/problems related to using <b=
r>
&gt; JGroups &lt;<a href=3D"mailto:[email protected]" =
target=3D"_blank">[email protected]</a> <br>
&gt; &lt;mailto:<a href=3D"mailto:[email protected]" t=
arget=3D"_blank">[email protected]</a>&gt;&gt; wrote:<=
br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0Why do you create your own base channel? You should=
 fetch the existing<br>
&gt;=C2=A0 =C2=A0 =C2=A0JChannel from Infinispan and create a ForkChannel o=
ver it.<br>
&gt;=C2=A0 =C2=A0 =C2=A0Which ctor are you missing? new JChannel(InputStrea=
m) still exists!<br>
&gt;=C2=A0 =C2=A0 =C2=A0Cheers,<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0On 13.01.20 16:37, Questions/problems related to us=
ing JGroups wrote:<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; Hey all,<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt;<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; So I recently upgraded to Infinispan 10.1.0.F=
inal and it came<br>
&gt;=C2=A0 =C2=A0 =C2=A0with a few<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; surprises with the JGroups update, a few of t=
he constructors in<br>
&gt;=C2=A0 =C2=A0 =C2=A0JChannel<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; are no longer available - it was fast to repl=
ace this with<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; org.jgroups.conf.XmlConfigurator , however, t=
he hijacked channel<br>
&gt;=C2=A0 =C2=A0 =C2=A0on the<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; other hand seems to be broken / non functiona=
l (see logs below)..<br>
&gt;=C2=A0 =C2=A0 =C2=A0before<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; digging into the Infinispan Jgroups bootstrap=
 code too far I<br>
&gt;=C2=A0 =C2=A0 =C2=A0thought it<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; might be worth reaching out here just in case=
 someone has already<br>
&gt;=C2=A0 =C2=A0 =C2=A0run<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; into this problem.<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt;<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; 2020-01-13T16:11:15,444 WARN =C2=A0[jgroups-6=
,space-service-1]<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; (org.jgroups.protocols.FORK) space-service-1:=
 fork-channel for<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; id=3Dlead-hijacker not found; discarding mess=
age []<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; 2020-01-13T16:11:15,466 WARN =C2=A0[jgroups-6=
,space-service-1]<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; (org.jgroups.protocols.FORK) space-service-1:=
 fork-channel for<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; id=3Dlead-hijacker not found; discarding mess=
age []<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; 2020-01-13T16:11:15,490 WARN =C2=A0[jgroups-6=
,space-service-1]<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; (org.jgroups.protocols.FORK) space-service-1:=
 fork-channel for<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; id=3Dlead-hijacker not found; discarding mess=
age []<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; 2020-01-13T16:11:15,512 WARN =C2=A0[jgroups-6=
,space-service-1]<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; (org.jgroups.protocols.FORK) space-service-1:=
 fork-channel for<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; id=3Dlead-hijacker not found; discarding mess=
age []<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; 2020-01-13T16:11:15,917 WARN =C2=A0[jgroups-6=
,space-service-1]<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; (org.jgroups.protocols.FORK) space-service-1:=
 fork-channel for<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; id=3Dlead-hijacker not found; discarding mess=
age []<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt;<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; Cheers,<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt;<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; --<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; Johno Crawford<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt;<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt;<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; _____________________________________________=
__<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; javagroups-users mailing list<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; <a href=3D"mailto:[email protected]=
ceforge.net" target=3D"_blank">[email protected]</a><b=
r>
&gt;=C2=A0 =C2=A0 =C2=A0&lt;mailto:<a href=3D"mailto:javagroups-users@lists=
.sourceforge.net" target=3D"_blank">[email protected]<=
/a>&gt;<br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt; <a href=3D"https://lists.sourceforge.net/list=
s/listinfo/javagroups-users" rel=3D"noreferrer" target=3D"_blank">https://l=
ists.sourceforge.net/lists/listinfo/javagroups-users</a><br>
&gt;=C2=A0 =C2=A0 =C2=A0 &gt;<br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0-- <br>
&gt;=C2=A0 =C2=A0 =C2=A0Bela Ban | <a href=3D"http://www.jgroups.org" rel=
=3D"noreferrer" target=3D"_blank">http://www.jgroups.org</a><br>
&gt; <br>
&gt; <br>
&gt; <br>
&gt;=C2=A0 =C2=A0 =C2=A0_______________________________________________<br>
&gt;=C2=A0 =C2=A0 =C2=A0javagroups-users mailing list<br>
&gt;=C2=A0 =C2=A0 =C2=A0<a href=3D"mailto:[email protected]=
e.net" target=3D"_blank">[email protected]</a><br>
&gt;=C2=A0 =C2=A0 =C2=A0&lt;mailto:<a href=3D"mailto:javagroups-users@lists=
.sourceforge.net" target=3D"_blank">[email protected]<=
/a>&gt;<br>
&gt;=C2=A0 =C2=A0 =C2=A0<a href=3D"https://lists.sourceforge.net/lists/list=
info/javagroups-users" rel=3D"noreferrer" target=3D"_blank">https://lists.s=
ourceforge.net/lists/listinfo/javagroups-users</a><br>
&gt; <br>
&gt; <br>
&gt; <br>
&gt; -- <br>
&gt; Johno Crawford<br>
&gt; <br>
&gt; <br>
&gt; _______________________________________________<br>
&gt; javagroups-users mailing list<br>
&gt; <a href=3D"mailto:[email protected]" target=3D"_b=
lank">[email protected]</a><br>
&gt; <a href=3D"https://lists.sourceforge.net/lists/listinfo/javagroups-use=
rs" rel=3D"noreferrer" target=3D"_blank">https://lists.sourceforge.net/list=
s/listinfo/javagroups-users</a><br>
&gt; <br>
<br>
-- <br>
Bela Ban | <a href=3D"http://www.jgroups.org" rel=3D"noreferrer" target=3D"=
_blank">http://www.jgroups.org</a><br>
<br>
<br>
<br>
_______________________________________________<br>
javagroups-users mailing list<br>
<a href=3D"mailto:[email protected]" target=3D"_blank"=
>[email protected]</a><br>
<a href=3D"https://lists.sourceforge.net/lists/listinfo/javagroups-users" r=
el=3D"noreferrer" target=3D"_blank">https://lists.sourceforge.net/lists/lis=
tinfo/javagroups-users</a><br>
</blockquote></div><br clear=3D"all"><div><br></div>-- <br><div dir=3D"ltr"=
 class=3D"gmail_signature">Johno Crawford</div>

--000000000000a3af6e059c2919b6--


--===============5103686303414308639==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline


--===============5103686303414308639==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
javagroups-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/javagroups-users

--===============5103686303414308639==--