You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jmeter-dev@jakarta.apache.org by bu...@apache.org on 2007/05/02 15:24:48 UTC

DO NOT REPLY [Bug 39427] - HTTP Proxy Server overwrites selected item

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=39427>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=39427





------- Additional Comments From alf@i100.no  2007-05-02 06:24 -------
Created an attachment (id=20089)
 --> (http://issues.apache.org/bugzilla/attachment.cgi?id=20089&action=view)
Suggested patch

I've looked at this issue today.
To me, the problem seems to be caused by the handling of the "current node" in
GUI. When a sample is added to the test plan, the correct GUI component is used
for the sample. There is only one instance of the GUI class, and this class is
reused for each sample being constructed and put into the plan. Somehow, the
"current node / gui node" becomes incorrect, and the selected item in the GUI
is incorrectly updated.

In the JMeterTreeModel.addComponent method, the current GUI state is "stored"
in the test element for the node by
GuiPackage.getInstance().updateCurrentNode().
Then the GUI component for the test element being added is retrieved by
JMeterGUIComponent guicomp = GuiPackage.getInstance().getGui(component).

Then the state is copied from the "test element" to the GUI instance by
guicomp.configure(component);
Then the state of the GUI instance is copied to the test element by
guicomp.modifyTestElement(component);

Finally, from the comment, it seems like the GUI instance should be put back to
the state it was in when the state for the current node was stored, by "
GuiPackage.getInstance().getCurrentGui(); // put the gui object back
// to the way it was."

However, this is not what is happening when running the Proxy, and selecting a
sample in the test plan, and then entering an URL in the browser.
In that case, "GuiPackage.getInstance().getCurrentGui()" causes the GUI state
of the newly added test element to be copied to the test element that the user
had selected in the test plan before entering the URL in the browser.

By applying this suggested patch, I can selected items in the test plan while
the proxy is running, and the item will not change, even if new items are added
to the test plan by the proxy because of browser activity.

Perhaps someone can explain what the lines I suggest to delete are meant to do
?
And / or give some input on scenarios that should be tested to check that
things still work, I'm mainly thinking about other scenarios than using the
Proxy.


-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org