Bug 64962 - Save sub results doesn't show all sub results in VRT listener
Summary: Save sub results doesn't show all sub results in VRT listener
Status: RESOLVED FIXED
Alias: None
Product: JMeter
Classification: Unclassified
Component: Main (show other bugs)
Version: Nightly (Please specify date)
Hardware: PC All
: P2 normal (vote)
Target Milestone: JMETER 5.4.1
Assignee: JMeter issues mailing list
URL:
Keywords: FixedInTrunk, PatchAvailable
Depends on:
Blocks:
 
Reported: 2020-12-07 22:08 UTC by eR@SeR
Modified: 2021-02-23 22:39 UTC (History)
1 user (show)



Attachments
jmx file (17.08 KB, application/xml)
2020-12-07 22:08 UTC, eR@SeR
Details
Recurse into sub results when saving CSV from VRT (1.43 KB, patch)
2020-12-09 18:59 UTC, Felix Schumacher
Details | Diff
transaction controllers are shown at the bottom, sampler-subresult are switched (92.64 KB, image/jpeg)
2020-12-14 12:09 UTC, eR@SeR
Details
Recurse into sub results when saving CSV from VRT (1.80 KB, patch)
2020-12-15 16:51 UTC, Felix Schumacher
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description eR@SeR 2020-12-07 22:08:43 UTC
Created attachment 37592 [details]
jmx file

Hello,

If "Save sub results" is checked in Configuration menu in VRT listener, it seems that only one child sub result is visible when csv file is loaded. If the same is done using jtl file, all sub results are visible. Is this intended behavior? Please run jmx file and load csv/jtl files in VRT listener and compare results.

Jmeter 5.4.1 c7f309f
Microsoft Windows 10 Pro 64-bit
java version "1.8.0_251"
Comment 1 Felix Schumacher 2020-12-09 18:59:18 UTC
Created attachment 37597 [details]
Recurse into sub results when saving CSV from VRT

The attached patch will probably fix your problem. At the moment the CSV implementation saves only one level deep of subresults.
Comment 2 Felix Schumacher 2020-12-09 19:00:40 UTC
@all should we include this in the next release (4.5.1), or should we play safe and wait for the next one after this?

@eR@SeR are you able to compile the code with the patch yourself?
Comment 3 eR@SeR 2020-12-10 00:06:27 UTC
No, I'm not able to compile the code, unfortunately. Can you do it instead and send me the link to download binary?
Comment 4 Philippe Mouawad 2020-12-10 07:54:24 UTC
(In reply to Felix Schumacher from comment #2)
> @all should we include this in the next release (4.5.1), or should we play
> safe and wait for the next one after this?
> 
> @eR@SeR are you able to compile the code with the patch yourself?

Hello,
I am in favor of playing safe.
Regards
Comment 5 eR@SeR 2020-12-14 12:09:47 UTC
Created attachment 37609 [details]
transaction controllers are shown at the bottom, sampler-subresult are switched

Hello,

@Felix
Thank you for sending me the compiled JMeter. Subresults are visible on the provided and real test plan.

However, when csv file is loaded, the order of sampler and subresult is switched in both test plans if samplers are inside Transaction Controller and 'Generate parent sample' is checked. Please run jmx from attachment 37592 [details].

If one or more Transaction controllers are added as a parent of Transaction controller and 'Generate parent sample' is checked in all, Transaction Controllers are shown at the bottom, instead to follow the order of appearance when actual test is run. When jtl file is loaded, the order of elements and subresults are fine. Check image for more info.

Jmeter 5.4.1 3e5421f
Microsoft Windows 10 Pro 64-bit
java version "1.8.0_251"
Comment 6 Felix Schumacher 2020-12-15 16:51:55 UTC
Created attachment 37617 [details]
Recurse into sub results when saving CSV from VRT

Thanks for the feedback. The order should be fixed now.
Comment 7 eR@SeR 2020-12-16 01:43:30 UTC
Hi Felix,

Well done! The order of sub results has been fixed on the provided and real test plan. Thank you.

Jmeter 5.4.1 58ad5bc
Microsoft Windows 10 Pro 64-bit
java version "1.8.0_251"
Comment 8 eR@SeR 2021-01-27 23:23:50 UTC
Hi Felix,

I'm not sure if this fix is not included in latest nightly accidentally. Just to update in case if it is.

Jmeter 5.5 ff9866a
Microsoft Windows 10 Pro 64-bit
java version "15.0.1" 2020-10-20
Comment 9 Felix Schumacher 2021-02-11 19:20:06 UTC
@Nikola, can you test the next build from trunk or nightly?

The fix has not been in JMeter 5.4.1 as this is on the border between a bug fix and an enhancement. But it is included in trunk now and will be in the next release.

commit f905a07259e5e6c092a619ea3be281f7e6d041e0
AuthorDate: Thu Dec 10 17:02:13 2020 +0100

    Save CSV sub-results recursively from Visual Result Tree
    
    Bugzilla Id: 64962
---
 .../java/org/apache/jmeter/save/CSVSaveService.java    | 18 ++++++++++++++----
 xdocs/changes.xml                                      |  1 +
 2 files changed, 15 insertions(+), 4 deletions(-)
Comment 10 eR@SeR 2021-02-15 01:52:37 UTC
Hi Felix,

Wrong https://bz.apache.org/bugzilla/attachment.cgi?id=37597&action=diff patch is applied. Same issue described in https://bz.apache.org/bugzilla/show_bug.cgi?id=64962#c5 happens. The one that worked fine is https://bz.apache.org/bugzilla/attachment.cgi?id=37617&action=diff

(In reply to Felix Schumacher from comment #9)
> The fix has not been in JMeter 5.4.1 as this is on the border between a bug
> fix and an enhancement. But it is included in trunk now and will be in the
> next release.
I meant to add in nightly that was published on Jan 26th, not to add in version 5.4.1 that was already published.

Jmeter 5.5 acdb648
Microsoft Windows 10 Pro 64-bit
java version "15.0.1" 2020-10-20
Comment 11 Felix Schumacher 2021-02-15 16:38:03 UTC
@nikola could you please test again, the order should be correct now.

commit eb8c962ef132964041ab10d12ba2bd168c68dfdb
Author: Felix Schumacher <felix.schumacher@internetallee.de>
AuthorDate: Mon Feb 15 17:31:33 2021 +0100

    Save sub-results in correct order
    
    Bugzilla Id: 64962
---
 src/core/src/main/java/org/apache/jmeter/save/CSVSaveService.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Comment 12 eR@SeR 2021-02-23 22:39:17 UTC
Hi Felix,

The order is correct now. Thank you.

Jmeter 5.5 25ab888
Microsoft Windows 10 Pro 64-bit
java version "15.0.1" 2020-10-20