specify dhttp proxy+port

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

specify dhttp proxy+port

hc narc
Hi all,
 
A small question:
 
When I have to specify port and proxy for running a java code, I do:
java  -Dhttp.proxyHost=host -Dhttp.proxyPort=port
 
How do I do the same using groovy?
 
groovy -Dhttp...  dosent seem to exisit.
 
Thanks a lot!
Hector 


Do you Yahoo!?
Next-gen email? Have it all with the all-new Yahoo! Mail Beta.
Reply | Threaded
Open this post in threaded view
|

Re: specify dhttp proxy+port

David Budworth-3
Just set them as JAVA_OPTS environment variable.

from something like bash on a *nix environment you can do (all on one cmd line)
JAVA_OPTS="-Dhttp..." groovy [scriptname etc...]

that sets the var for that run only (as in, not permanently in your environment.

other wise just do the appropriate env setting mechanism for your platform / shell

On 7/25/06, hc narc <[hidden email]> wrote:
Hi all,
 
A small question:
 
When I have to specify port and proxy for running a java code, I do:
java  -Dhttp.proxyHost=host -Dhttp.proxyPort=port
 
How do I do the same using groovy?
 
groovy -Dhttp...  dosent seem to exisit.
 
Thanks a lot!
Hector 


Do you Yahoo!?
Next-gen email? Have it all with the <a href="http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers" title="http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)"> all-new Yahoo! Mail Beta.


Reply | Threaded
Open this post in threaded view
|

Re: specify dhttp proxy+port

Kiran-2
hi All,

I am also facing similar problem. I am inside firewall. So need to set the HTTP proxy.
I am trying to run the Currency Conversion example given in ( http://docs.codehaus.org/display/GROOVY/Groovy+SOAP)
But it fails because of being behind my company firewall. So far not succesful in setting the proxy.

I am running on Windows XP
Rgds
Kiran





On 7/25/06, David Budworth <[hidden email]> wrote:
Just set them as JAVA_OPTS environment variable.

from something like bash on a *nix environment you can do (all on one cmd line)
JAVA_OPTS="-Dhttp..." groovy [scriptname etc...]

that sets the var for that run only (as in, not permanently in your environment.

other wise just do the appropriate env setting mechanism for your platform / shell


On 7/25/06, hc narc <[hidden email]> wrote:
Hi all,
 
A small question:
 
When I have to specify port and proxy for running a java code, I do:
java  -Dhttp.proxyHost=host -Dhttp.proxyPort=port
 
How do I do the same using groovy?
 
groovy -Dhttp...  dosent seem to exisit.
 
Thanks a lot!
Hector 


Do you Yahoo!?
Next-gen email? Have it all with the <a href="http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers" title="http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers (http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers)" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)"> all-new Yahoo! Mail Beta.



Reply | Threaded
Open this post in threaded view
|

Re: specify dhttp proxy+port

hc narc
Hi,
 
Thanx David. Your suggestion works!
 
Hector

"Kiran K.G." <[hidden email]> wrote:
hi All,

I am also facing similar problem. I am inside firewall. So need to set the HTTP proxy.
I am trying to run the Currency Conversion example given in ( http://docs.codehaus.org/display/GROOVY/Groovy+SOAP)
But it fails because of being behind my company firewall. So far not succesful in setting the proxy.

I am running on Windows XP
Rgds
Kiran





On 7/25/06, David Budworth <[hidden email]> wrote:
Just set them as JAVA_OPTS environment variable.

from something like bash on a *nix environment you can do (all on one cmd line)
JAVA_OPTS="-Dhttp..." groovy [scriptname etc...]

that sets the var for that run only (as in, not permanently in your environment.

other wise just do the appropriate env setting mechanism for your platform / shell


On 7/25/06, hc narc <[hidden email]> wrote:
Hi all,
 
A small question:
 
When I have to specify port and proxy for running a java code, I do:
java  -Dhttp.proxyHost=host -Dhttp.proxyPort=port
 
How do I do the same using groovy?
 
groovy -Dhttp...  dosent seem to exisit.
 
Thanks a lot!
Hector 

Do you Yahoo!?
Next-gen email? Have it all with the <A title="http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers (http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers)" onclick="return top.js.OpenExtLink(window,event,this)" href="http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers" target=_blank>all-new Yahoo! Mail Beta.




Talk is cheap. Use Yahoo! Messenger to make PC-to-Phone calls. Great rates starting at 1¢/min.
Reply | Threaded
Open this post in threaded view
|

Re: specify dhttp proxy+port

Kiran-2
It works from Java, but not from Groovy code.
But if u wrap ur code in Java and then call it from Groovy you are fine.


On 7/25/06, hc narc <[hidden email]> wrote:
Hi,
 
Thanx David. Your suggestion works!
 
Hector


"Kiran K.G." <[hidden email]> wrote:
hi All,

I am also facing similar problem. I am inside firewall. So need to set the HTTP proxy.
I am trying to run the Currency Conversion example given in (<a href="http://docs.codehaus.org/display/GROOVY/Groovy+SOAP" title="http://docs.codehaus.org/display/GROOVY/Groovy+SOAP" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)"> http://docs.codehaus.org/display/GROOVY/Groovy+SOAP)
But it fails because of being behind my company firewall. So far not succesful in setting the proxy.

I am running on Windows XP
Rgds
Kiran





On 7/25/06, David Budworth <[hidden email]> wrote:
Just set them as JAVA_OPTS environment variable.

from something like bash on a *nix environment you can do (all on one cmd line)
JAVA_OPTS="-Dhttp..." groovy [scriptname etc...]

that sets the var for that run only (as in, not permanently in your environment.

other wise just do the appropriate env setting mechanism for your platform / shell


On 7/25/06, hc narc <[hidden email]> wrote:
Hi all,
 
A small question:
 
When I have to specify port and proxy for running a java code, I do:
java  -Dhttp.proxyHost=host -Dhttp.proxyPort=port
 
How do I do the same using groovy?
 
groovy -Dhttp...  dosent seem to exisit.
 
Thanks a lot!
Hector 

Do you Yahoo!?
Next-gen email? Have it all with the <a title="http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers (http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers) (http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers)" href="http://us.rd.yahoo.com/evt=42241/*http://advision.webevents.yahoo.com/handraisers" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)"> all-new Yahoo! Mail Beta.




Talk is cheap. Use Yahoo! Messenger to make PC-to-Phone calls. <a href="http://us.rd.yahoo.com/mail_us/taglines/postman7/*http://us.rd.yahoo.com/evt=39666/*http://messenger.yahoo.com" title="http://us.rd.yahoo.com/mail_us/taglines/postman7/*http://us.rd.yahoo.com/evt=39666/*http://messenger.yahoo.com" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)"> Great rates starting at 1¢/min.