jmeter-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject [Bug 62887] SampleLabel displays incorrectly in Jmeter 5.0
Date Mon, 05 Nov 2018 20:57:28 GMT
https://bz.apache.org/bugzilla/show_bug.cgi?id=62887

Philippe Mouawad <p.mouawad@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO

--- Comment #3 from Philippe Mouawad <p.mouawad@ubik-ingenierie.com> ---
(In reply to Alan Silva from comment #2)
> Sure thing.
> 
> I'm using a Parameterized Controller
> (https://jmeter-plugins.org/wiki/ParameterizedController/) to call a custom
> HLS sampler (an Apple media streaming protocol).
> 
> 
> I've found the change to be in
> src/core/org/apache/jmeter/samplers/SampleResult.java in the:
> 
> public void addSubResult(SampleResult subResult) {
>     addSubResult(subResult, true);
> }
> 
> which in turns calls 
> 
> public void addSubResult(SampleResult subResult, boolean renameSubResults)
> 
> to clobber my custom result label names.
> 
> I honestly find this design choice pretty strange because:
> 1 - It breaks labels for users upgrading from Jmeter 4.0 to Jmeter 5.0 and
> the change is not explicitly documented in the Jmeter 5.0 release notes
> (https://jmeter.apache.org/changes.html)


Yes it should have been documented. 


> 2 - Clobbering a user's SampleResult labels by default is ill-advised.

Still, modifying labels is a bit of an edgy case.
> 
> I would propose simply doing the following:
> 
> public void addSubResult(SampleResult subResult) {
>     addSubResult(subResult, subResult.getSampleLabel().isEmpty());
> }
> 
> 1 - If the user's label is empty, cool, use the new renameSubResults feature.
> 2 - If it's not, respect the given label to the SampleResult object.
> 
> I wouldn't even make
> 
> addSubResult(SampleResult subResult, boolean renameSubResults)
> 
> a public method. It should only be called privately due to the lack of a
> SampleLabel by a user.
> 

Can you fork our repository on github, apply your patch and run test as per:

http://jmeter.apache.org/building.html

This way you'll see if your approach works and if it doesn't break things. 


> 
> The scenario in which a user goes through the effort of naming their
> SampleResult label and then calling addSubResult(subResult, true) makes no
> sense to me. The logical thing to do if they if don't care about their label
> anymore would be simply to remove their call to subResult.setSampleLabel().
> 
> What are your thoughts on this?

I'll be able to look at this issue in more details only in few days.
So for now no answer on my side yet.

> Cheers.

-- 
You are receiving this mail because:
You are the assignee for the bug.
Mime
View raw message