Thanks for the replies. I've decided to go with the following technique.
 
HttpClient client = new HttpClient();
PostMethod method = new PostMethod(url);
 
client.getParams().setAuthenticationPreemptive(true);
 
//Preemptive authentication mode also requires default Credentials
//to be set for the target or proxy host against which preemptive authentication is to be attempted.
//Failure to provide default credentials will render the preemptive authentication mode ineffective.
Credentials defaultcreds = new UsernamePasswordCredentials(username, password);
client.getState().setCredentials(new AuthScope(ip, port, AuthScope.ANY_REALM), defaultcreds);
 
try
{
    int result = client.executeMethod(method);
    System.out.println (result);
}
catch (IOException ioe)
{
    System.out.println (ioe.getMessage());
}
 
 

On 9/6/06, Yusuf Jakoet <[EMAIL PROTECTED]> wrote:
Thanks Jeff and Soren
 
The server's running on a Windows box.
 
 I need to be able to do a webapp reload from a Java application.
 
Then Cargo is the way to go.Have you looked at the API ?It's really easy to use.I've used it myself to do remote deployments/re-deployments to Tomcat

--


Jeff  Mutonho

GoogleTalk : ejbengine
Skype        : ejbengine
Registered Linux user number 366042

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CTJUG Forum" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/CTJUG-Forum
For the ctjug home page see http://www.ctjug.org.za
-~----------~----~----~----~------~----~------~--~---

Reply via email to