java - Trying to get the final URL in Gridner using Jython script -


i working on grinder tool load testing. in script, have url follows multiple redirects , lands on particular url. want final url of request after multiple redirects using jython script grinder. doing

test1 = test(1, "request resource") request1 = httprequest() test1.record(request1)  class testrunner:   def __call__(self):     result = request1.get("https://internal.autodesk360beta.com/")     result2 = result.geteffectiveuri().tostring()     print result2 

i getting final uri same 1 instead of long final url looks https://accounts.autodesk.com/logon?returnurl=%2fauthorize%3f.. , on.. appreciated.

by default, grinder follows redirects automatically. however, can disable behavior , explicitly follow each redirect in jython code. approach you'll have access each url in redirect chain.


Comments

Popular posts from this blog

java.util.scanner - How to read and add only numbers to array from a text file -

rewrite - Trouble with Wordpress multiple custom querystrings -