hi,
I am new to google data api. I am trying to access the Picasa data api
using java.
I used the gdata client library and tried to do "ClientLogin" using
the documentation given

http://code.google.com/apis/picasaweb/developers_guide_java.html

but received an exception.
can u help me out .....wat cld be the possible reasons.

Thanx.



Here is the code->
/*code


import com.google.gdata.util.AuthenticationException;
import com.google.gdata.util.ServiceException;
import java.io.File;
import java.io.IOException;
import java.net.MalformedURLException;
import java.net.URL;

import com.google.gdata.client.*;
import com.google.gdata.client.photos.*;
import com.google.gdata.data.*;
import com.google.gdata.data.media.*;
import com.google.gdata.data.photos.*;
import java.net.Authenticator;
import java.util.logging.Level;
import java.util.logging.Logger;

public class PicasaAccess {

    public static void main(String args[]){

        Authenticator.setDefault(new Authentication
("myname","myproxpass"));
        System.setProperty("http.proxyHost", "172.31.1.4");
        System.setProperty("http.proxyPort", "8080");


        PicasawebService myService = new PicasawebService("example");
        try {
            myService.setUserCredentials("[EMAIL PROTECTED]", "mypass");
        } catch (AuthenticationException ex) {
            Logger.getLogger(PicasaAccess.class.getName()).log
(Level.SEVERE, null, ex);
            System.out.println("authentication prob");
        }

    }

}


code
*/


"here are the errors"



com.google.gdata.util.AuthenticationException: Error connecting with
login URI
        at com.google.gdata.client.GoogleAuthTokenFactory.getAuthToken
(GoogleAuthTokenFactory.java:420)
        at
com.google.gdata.client.GoogleAuthTokenFactory.setUserCredentials
(GoogleAuthTokenFactory.java:301)
        at com.google.gdata.client.GoogleService.setUserCredentials
(GoogleService.java:323)
        at com.google.gdata.client.GoogleService.setUserCredentials
(GoogleService.java:300)
        at gdata.PicasaAccess.main(PicasaAccess.java:42)
Caused by: java.net.SocketException: Connection reset by peer: connect
        at java.net.PlainSocketImpl.socketConnect(Native Method)
        at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:
333)
        at java.net.PlainSocketImpl.connectToAddress
(PlainSocketImpl.java:195)
        at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
        at java.net.Socket.connect(Socket.java:519)
        at java.net.Socket.connect(Socket.java:469)
        at sun.net.NetworkClient.doConnect(NetworkClient.java:157)
        at sun.net.www.http.HttpClient.openServer(HttpClient.java:394)
        at sun.net.www.http.HttpClient.openServer(HttpClient.java:529)
        at sun.net.www.protocol.https.HttpsClient.<init>
(HttpsClient.java:271)
        at sun.net.www.protocol.https.HttpsClient.New(HttpsClient.java:
328)
        at
sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient
(AbstractDelegateHttpsURLConnection.java:172)
        at sun.net.www.protocol.http.HttpURLConnection.plainConnect
(HttpURLConnection.java:729)

        at
sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect
(AbstractDelegateHttpsURLConnection.java:158)
        at sun.net.www.protocol.http.HttpURLConnection.getOutputStream
(HttpURLConnection.java:832)
        at
sun.net.www.protocol.https.HttpsURLConnectionImpl.getOutputStream
(HttpsURLConnectionImpl.java:230)
        at
com.google.gdata.client.GoogleAuthTokenFactory.makePostRequest
(GoogleAuthTokenFactory.java:477)
        at com.google.gdata.client.GoogleAuthTokenFactory.getAuthToken
(GoogleAuthTokenFactory.java:418)
        ... 4 more



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Picasa Web Albums API" 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/Google-Picasa-Data-API?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to