It sounds like you have a proxy server that requires login info? JMeter was
recently upgraded to handle this - when you set the proxy server and port on the
command line when starting JMeter, you can also set the username and password.
You can read about it at:
http://jakarta.apache.org/jmeter/usermanual/get-started.html#running
-Mike
On 6 Sep 2002 at 15:43, [EMAIL PROTECTED] wrote:
> Hi All,
>
> can anyone tell me the difference between using Proxy setting at start up
> and using the authManager in a test plan. I have an issue where if I use a
> simple piece of code see below to access a web page it works, but through
> JMeter (which I know uses the java.net. classes) to open the same URL
> nothing happens.
>
> thanks
>
> Andrew.
>
>
> URL url = new URL(urlName);
>
> HttpURLConnection uc =
> (HttpURLConnection)url.openConnection();
>
> // the following line makes URLConnection look
> like MSIE
> uc.setRequestProperty("User-Agent", "Mozilla/4.0
> (compatible; MSIE 5.01; Windows NT)");
>
> uc.setRequestMethod("GET");
>
> // the following three lines calculate a
> BASE64-encoded username/password for the proxy
>
> String userName = ""; // put your proxy/internet
> username here
> String passWord = ""; // put your proxy/internet
> password here
> String auth = "Basic " + new
> sun.misc.BASE64Encoder().encode((userName + ":" + passWord).getBytes());
>
> // comment out the following three lines to switch
> off proxy access
> uc.setRequestProperty("Proxy-Authorization", auth);
> System.setProperty("http.proxyHost",
> "proxy.xxx.xxx");
> System.setProperty("http.proxyPort", "XXX");
--
Michael Stover
[EMAIL PROTECTED]
Yahoo IM: mstover_ya
ICQ: 152975688
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>