Bug 42185 - If a HTTP Sampler follows a redirect, and is set up to download images, then images are downloaded multiple times
Summary: If a HTTP Sampler follows a redirect, and is set up to download images, then ...
Alias: None
Product: JMeter
Classification: Unclassified
Component: HTTP (show other bugs)
Version: 2.2
Hardware: All All
: P2 normal (vote)
Target Milestone: ---
Assignee: JMeter issues mailing list
Depends on:
Reported: 2007-04-22 05:24 UTC by Alf Hogemark
Modified: 2007-04-22 06:51 UTC (History)
0 users

Test plan to show the problem (6.46 KB, application/octet-stream)
2007-04-22 05:26 UTC, Alf Hogemark
Suggested patch (2.39 KB, patch)
2007-04-22 05:30 UTC, Alf Hogemark
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alf Hogemark 2007-04-22 05:24:48 UTC
If you tick on the "Download images" in the HTTP Request GUI, to make the sample
download images and other resources referenced on the web page, and you are
testing a URL which will return a redirect that the sampler follows, then you
can see in the "ViewFullResultsVisualizer" that the sampler will actually
download all the references resources twice. In fact, I think it will download
it as many times as it follows a redirect for the sample.
Comment 1 Alf Hogemark 2007-04-22 05:26:21 UTC
Created attachment 20009 [details]
Test plan to show the problem

If you run this test plan, and look in the "View Results Tree", and expand the
nodes, you will see that images and javascript and css files are downloaded
Comment 2 Alf Hogemark 2007-04-22 05:30:42 UTC
Created attachment 20010 [details]
Suggested patch

The suggested patch makes the images and other resources only be downloaded for
the sample that sampling the url one was redirected to.

The patch also takes away incorrect "TO-DO" text for following redirects in
Norwegian message file.
Comment 3 Sebb 2007-04-22 06:51:15 UTC

Patch applied in r531180

BTW, I just removed the English translation for "follow_redirects" - if a 
property is missing, it should pick up the default English translation anyway.