You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jmeter.apache.org by Philippe Mouawad <ph...@gmail.com> on 2016/08/03 20:04:47 UTC

PR221 : Guava or concurrentlinkedhashmap or Caffeine after Java8 migration

Hello,

We have a PR-221 which relies on Guava.

There is a discussion on github on the dependency on guava.

What do team members think about this:
- Should we introduce guava (which can be used for other things by the way
not only for this feature)
- Should we use https://github.com/ben-manes/concurrentlinkedhashmap
- Should we migrate to Java 8 and then use
https://github.com/ben-manes/caffeine



I vote for guava + PR integration as :

   - I see interesting things in Guava for JMeter even if we move to Java 8:
      - cache
      - annotations
      - collections
      - ...

Although it's a minor agurment, the PR is ready to go, it's not if we
select CLHM or caffeine.




-- 
Regards.
Philippe

Re: PR221 : Guava or concurrentlinkedhashmap or Caffeine after Java8 migration

Posted by Philippe Mouawad <ph...@gmail.com>.
Hello,
As a conclusion :
- Ok for Java 8 for the N+2 release
- No go for guava integration

@Vladimir, you were waiting for this thread to end, I think you're
now welcome to propose a new patch for the blocker issue of 3.1 related to
bad throughput due to Css parsing cache access concurrency

Regards
Philippe

On Friday, August 12, 2016, sebb <se...@gmail.com> wrote:

> I'm OK with requiring Java 8.
>
> I don't think we should make Guava a required dependency.
>
> On 12 August 2016 at 21:06, Philippe Mouawad <philippe.mouawad@gmail.com
> <javascript:;>> wrote:
> > Hi,
> > Sebb, Milamber, Antonio,
> > any thoughts on this ?
> >
> >
> > Thanks
> >
> > On Thu, Aug 11, 2016 at 7:38 AM, Felix Schumacher <
> > felix.schumacher@internetallee.de <javascript:;>> wrote:
> >
> >>
> >>
> >> Am 9. August 2016 07:42:39 MESZ, schrieb Philippe Mouawad <
> >> philippe.mouawad@gmail.com <javascript:;>>:
> >> >Hello,
> >> >Any thoughts on this ?
> >>
> >> To widen the discussion :)
> >>
> >> What about adding a full blown cache like commons jcs (is it still
> alive?)
> >> or ehcache, etc.
> >>
> >> Felix
> >>
> >> >Regards
> >> >
> >> >On Wednesday, August 3, 2016, Philippe Mouawad
> >> ><philippe.mouawad@gmail.com <javascript:;>>
> >> >wrote:
> >> >
> >> >> Hello,
> >> >>
> >> >> We have a PR-221 which relies on Guava.
> >> >>
> >> >> There is a discussion on github on the dependency on guava.
> >> >>
> >> >> What do team members think about this:
> >> >> - Should we introduce guava (which can be used for other things by
> >> >the way
> >> >> not only for this feature)
> >> >> - Should we use https://github.com/ben-manes/concurrentlinkedhashmap
> >> >> - Should we migrate to Java 8 and then use
> >> >https://github.com/ben-manes/
> >> >> caffeine
> >> >>
> >> >>
> >> >>
> >> >> I vote for guava + PR integration as :
> >> >>
> >> >>    - I see interesting things in Guava for JMeter even if we move to
> >> >Java
> >> >>    8:
> >> >>       - cache
> >> >>       - annotations
> >> >>       - collections
> >> >>       - ...
> >> >>
> >> >> Although it's a minor agurment, the PR is ready to go, it's not if we
> >> >> select CLHM or caffeine.
> >> >>
> >> >>
> >> >>
> >> >>
> >> >> --
> >> >> Regards.
> >> >> Philippe
> >> >>
> >>
> >>
> >
> >
> > --
> > Cordialement.
> > Philippe Mouawad.
>


-- 
Cordialement.
Philippe Mouawad.

Re: PR221 : Guava or concurrentlinkedhashmap or Caffeine after Java8 migration

Posted by sebb <se...@gmail.com>.
I'm OK with requiring Java 8.

I don't think we should make Guava a required dependency.

On 12 August 2016 at 21:06, Philippe Mouawad <ph...@gmail.com> wrote:
> Hi,
> Sebb, Milamber, Antonio,
> any thoughts on this ?
>
>
> Thanks
>
> On Thu, Aug 11, 2016 at 7:38 AM, Felix Schumacher <
> felix.schumacher@internetallee.de> wrote:
>
>>
>>
>> Am 9. August 2016 07:42:39 MESZ, schrieb Philippe Mouawad <
>> philippe.mouawad@gmail.com>:
>> >Hello,
>> >Any thoughts on this ?
>>
>> To widen the discussion :)
>>
>> What about adding a full blown cache like commons jcs (is it still alive?)
>> or ehcache, etc.
>>
>> Felix
>>
>> >Regards
>> >
>> >On Wednesday, August 3, 2016, Philippe Mouawad
>> ><ph...@gmail.com>
>> >wrote:
>> >
>> >> Hello,
>> >>
>> >> We have a PR-221 which relies on Guava.
>> >>
>> >> There is a discussion on github on the dependency on guava.
>> >>
>> >> What do team members think about this:
>> >> - Should we introduce guava (which can be used for other things by
>> >the way
>> >> not only for this feature)
>> >> - Should we use https://github.com/ben-manes/concurrentlinkedhashmap
>> >> - Should we migrate to Java 8 and then use
>> >https://github.com/ben-manes/
>> >> caffeine
>> >>
>> >>
>> >>
>> >> I vote for guava + PR integration as :
>> >>
>> >>    - I see interesting things in Guava for JMeter even if we move to
>> >Java
>> >>    8:
>> >>       - cache
>> >>       - annotations
>> >>       - collections
>> >>       - ...
>> >>
>> >> Although it's a minor agurment, the PR is ready to go, it's not if we
>> >> select CLHM or caffeine.
>> >>
>> >>
>> >>
>> >>
>> >> --
>> >> Regards.
>> >> Philippe
>> >>
>>
>>
>
>
> --
> Cordialement.
> Philippe Mouawad.

Re: PR221 : Guava or concurrentlinkedhashmap or Caffeine after Java8 migration

Posted by Philippe Mouawad <ph...@gmail.com>.
Hi,
Sebb, Milamber, Antonio,
any thoughts on this ?


Thanks

On Thu, Aug 11, 2016 at 7:38 AM, Felix Schumacher <
felix.schumacher@internetallee.de> wrote:

>
>
> Am 9. August 2016 07:42:39 MESZ, schrieb Philippe Mouawad <
> philippe.mouawad@gmail.com>:
> >Hello,
> >Any thoughts on this ?
>
> To widen the discussion :)
>
> What about adding a full blown cache like commons jcs (is it still alive?)
> or ehcache, etc.
>
> Felix
>
> >Regards
> >
> >On Wednesday, August 3, 2016, Philippe Mouawad
> ><ph...@gmail.com>
> >wrote:
> >
> >> Hello,
> >>
> >> We have a PR-221 which relies on Guava.
> >>
> >> There is a discussion on github on the dependency on guava.
> >>
> >> What do team members think about this:
> >> - Should we introduce guava (which can be used for other things by
> >the way
> >> not only for this feature)
> >> - Should we use https://github.com/ben-manes/concurrentlinkedhashmap
> >> - Should we migrate to Java 8 and then use
> >https://github.com/ben-manes/
> >> caffeine
> >>
> >>
> >>
> >> I vote for guava + PR integration as :
> >>
> >>    - I see interesting things in Guava for JMeter even if we move to
> >Java
> >>    8:
> >>       - cache
> >>       - annotations
> >>       - collections
> >>       - ...
> >>
> >> Although it's a minor agurment, the PR is ready to go, it's not if we
> >> select CLHM or caffeine.
> >>
> >>
> >>
> >>
> >> --
> >> Regards.
> >> Philippe
> >>
>
>


-- 
Cordialement.
Philippe Mouawad.

Re: PR221 : Guava or concurrentlinkedhashmap or Caffeine after Java8 migration

Posted by Felix Schumacher <fe...@internetallee.de>.

Am 9. August 2016 07:42:39 MESZ, schrieb Philippe Mouawad <ph...@gmail.com>:
>Hello,
>Any thoughts on this ?

To widen the discussion :)

What about adding a full blown cache like commons jcs (is it still alive?) or ehcache, etc.

Felix

>Regards
>
>On Wednesday, August 3, 2016, Philippe Mouawad
><ph...@gmail.com>
>wrote:
>
>> Hello,
>>
>> We have a PR-221 which relies on Guava.
>>
>> There is a discussion on github on the dependency on guava.
>>
>> What do team members think about this:
>> - Should we introduce guava (which can be used for other things by
>the way
>> not only for this feature)
>> - Should we use https://github.com/ben-manes/concurrentlinkedhashmap
>> - Should we migrate to Java 8 and then use
>https://github.com/ben-manes/
>> caffeine
>>
>>
>>
>> I vote for guava + PR integration as :
>>
>>    - I see interesting things in Guava for JMeter even if we move to
>Java
>>    8:
>>       - cache
>>       - annotations
>>       - collections
>>       - ...
>>
>> Although it's a minor agurment, the PR is ready to go, it's not if we
>> select CLHM or caffeine.
>>
>>
>>
>>
>> --
>> Regards.
>> Philippe
>>


Re: PR221 : Guava or concurrentlinkedhashmap or Caffeine after Java8 migration

Posted by Vladimir Sitnikov <si...@gmail.com>.
Just to be clear: do you feel we are reinventing the wheel by not using
Guava? <-- I do not think so (modulo java 8)
Do you think we will get more user contributions by using Guava?

Philippe Mouawad:

> JMeter is core, although we should take into account the eco-system, I
> don't see why we should block ourselves from using a library because some
> plugin may in the future use it ?
>

JMeter does not have classloader separation between "core dependencies" and
"plugins". Am I wrong here?

JMeter users are not happy observing NoSuchMethod or NoClassDefFound
errors, thus the less dependencies core publishes to plugins, the less
amount of pain user would experience trying to figure out the proper jar
set.


Vladimir> org.apache.jmeter.core.shaded.guava...
Philippe> But if you want to contribute it why not.

I do not.
I might contribute if it was maven (I'm somewhat fluent in it), but that's
another story.


Philippe> I am not a guava expert, you seem to be.

I'm not. I just do not see lots of users/developers suggesting to replace
certain existing code parts with Guava equivalents.

Are we using immutable collections often?

I'm not a Guava expert, but I would like to hear some real-life cases for
JMeter where Guava would shine.

Philippe> Why not show here that guava brings nothing if java 8 is
introduced ?

I'm afraid that if we migrate to Guava _before_ Java 8, then lots of
contributions like "lets migrate to Guava's FluentIterable" would follow.
In Java 8 it is natural to use Stream API for that matter and so on.
The same goes for Guava's Optional, etc, etc.

Vladimir

Re: PR221 : Guava or concurrentlinkedhashmap or Caffeine after Java8 migration

Posted by Philippe Mouawad <ph...@gmail.com>.
On Wednesday, August 10, 2016, Vladimir Sitnikov <
sitnikov.vladimir@gmail.com> wrote:

> >Should we migrate to Java 8 and then use https://github.com/ben-manes/
> > caffeine
>
> +1 from me.
>
> >Should we migrate to Java 8
>
> That is +1 as well.
>
> >Should we introduce guava
>
> That would get -1 from me.
> The reasoning is: guava from plugins might interfere with guava from jmeter
> core, thus it might induce jar hell.


JMeter is core, although we should take into account the eco-system, I
don't see why we should block ourselves from using a library because some
plugin may in the future use it ?



>
> Caffeine (and CLHM) serve just a single purpose, so it will much less
> likely to cause compatibility issues (if that library is ever used by
> plugins).
>
> >Introduce guava in shaded mode (that is rename guava packages to
> org.apache.jmeter.core.shaded.guava...


This could be done by plugins also.
But if you want to contribute it why not.


>
> That would get +0 from me.
> It is safe from "jar hell issues", however, it is not clear what is the net
> win.
> Are there lots of features that are missing in java 8?


I am not a guava expert, you seem to be.
Why not show here that guava brings nothing if java 8 is introduced ?

>
> Vladimir
>


-- 
Cordialement.
Philippe Mouawad.

Re: PR221 : Guava or concurrentlinkedhashmap or Caffeine after Java8 migration

Posted by Vladimir Sitnikov <si...@gmail.com>.
>Should we migrate to Java 8 and then use https://github.com/ben-manes/
> caffeine

+1 from me.

>Should we migrate to Java 8

That is +1 as well.

>Should we introduce guava

That would get -1 from me.
The reasoning is: guava from plugins might interfere with guava from jmeter
core, thus it might induce jar hell.

Caffeine (and CLHM) serve just a single purpose, so it will much less
likely to cause compatibility issues (if that library is ever used by
plugins).

>Introduce guava in shaded mode (that is rename guava packages to
org.apache.jmeter.core.shaded.guava...

That would get +0 from me.
It is safe from "jar hell issues", however, it is not clear what is the net
win.
Are there lots of features that are missing in java 8?

Vladimir

Re: PR221 : Guava or concurrentlinkedhashmap or Caffeine after Java8 migration

Posted by Felix Schumacher <fe...@internetallee.de>.

Am 9. August 2016 07:42:39 MESZ, schrieb Philippe Mouawad <ph...@gmail.com>:
>Hello,
>Any thoughts on this ?
>Regards
>
>On Wednesday, August 3, 2016, Philippe Mouawad
><ph...@gmail.com>
>wrote:
>
>> Hello,
>>
>> We have a PR-221 which relies on Guava.
>>
>> There is a discussion on github on the dependency on guava.
>>
>> What do team members think about this:
>> - Should we introduce guava (which can be used for other things by
>the way
>> not only for this feature)
>> - Should we use https://github.com/ben-manes/concurrentlinkedhashmap
>> - Should we migrate to Java 8 and then use
>https://github.com/ben-manes/
>> caffeine

+1 after migration to java 8 (not before next year)

>>
>>
>>
>> I vote for guava + PR integration as :
>>
>>    - I see interesting things in Guava for JMeter even if we move to
>Java
>>    8:
>>       - cache
>>       - annotations
>>       - collections
>>       - ...

We already have the commons jars, which will probably overlap quite a lot with guava, is it worth the switch? 

>>
>> Although it's a minor agurment, the PR is ready to go, it's not if we
>> select CLHM or caffeine.

I wouldn't worry too much about it. 

Regards, 
Felix 

>>
>>
>>
>>
>> --
>> Regards.
>> Philippe
>>


Re: PR221 : Guava or concurrentlinkedhashmap or Caffeine after Java8 migration

Posted by Philippe Mouawad <ph...@gmail.com>.
Hello,
Any thoughts on this ?
Regards

On Wednesday, August 3, 2016, Philippe Mouawad <ph...@gmail.com>
wrote:

> Hello,
>
> We have a PR-221 which relies on Guava.
>
> There is a discussion on github on the dependency on guava.
>
> What do team members think about this:
> - Should we introduce guava (which can be used for other things by the way
> not only for this feature)
> - Should we use https://github.com/ben-manes/concurrentlinkedhashmap
> - Should we migrate to Java 8 and then use https://github.com/ben-manes/
> caffeine
>
>
>
> I vote for guava + PR integration as :
>
>    - I see interesting things in Guava for JMeter even if we move to Java
>    8:
>       - cache
>       - annotations
>       - collections
>       - ...
>
> Although it's a minor agurment, the PR is ready to go, it's not if we
> select CLHM or caffeine.
>
>
>
>
> --
> Regards.
> Philippe
>


-- 
Cordialement.
Philippe Mouawad.