You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Giuseppe Sarno <gs...@nortel.com> on 2007/01/23 11:46:57 UTC

HTTPConstants.BASIC_AUTHENTICATE not in the library . Help please.

Hi,
I'm trying to set up a connection with Basic Authentication (With
Axis2).

All the examples:
http://ws.apache.org/axis2/1_1/http-transport.html#preemptive_auth

Use the
options.setProperty(org.apache.axis2.transport.http.HTTPConstants.BASIC_
AUTHENTICATE,auth);

But 
HTTPConstants.BASIC_AUTHENTICATE doesn't exist.

Any idea ?

Also in the adb example how can we change the Stub to add the options ?

public
StockQuoteServiceStub(org.apache.axis2.context.ConfigurationContext
confi
gurationContext,
        java.lang.String targetEndpoint)
        throws org.apache.axis2.AxisFault {
         //To populate AxisService
         populateAxisService();
         populateFaults();

        _serviceClient = new
org.apache.axis2.client.ServiceClient(configuration
Context,_service);

<I THOUGHT HERE MIGHT BE OK>        
        
        configurationContext =
_serviceClient.getServiceContext().getConfigurati
onContext();

        _serviceClient.getOptions().setTo(new
org.apache.axis2.addressing.Endpoi
ntReference(
                targetEndpoint));