I answered your question in a previuos post. If you use getSession(true) you'll create a new session. You should pass false or no argument to method, instead.
-------------------------------------------------- From: "Stream" <[email protected]> Sent: Sunday, August 30, 2009 1:51 PM To: "Google App Engine" <[email protected]> Subject: [google-appengine] Re: Using Twitter4j in AppEngine > > I advanced on this a bit... you just need to have the server generate > the request url... then pass that back to the client... let the client > click on that and authenticate... that will cause twitter to redirect > to your site... (you'll need to edit your host file if you are testing > locally... since twitter only redirects to valid url's) > > Now I am stuck on how to persist data across requests. I tried using > the session state, however the object isn't being persisted across > requests ... perhaps because the twitter callback is considered a new > session? a bug in app engine? > > This is how i write: > this.getThreadLocalRequest().getSession(true).setAttribute > ("RequestToken", requestToken); > > This is how i read: > RequestToken requestToken = (RequestToken)this.getThreadLocalRequest > ().getSession(true).getAttribute("RequestToken"); > > anyone know whats wrong? > > > On Aug 24, 11:12 pm, Some Dude <[email protected]> wrote: >> Same here. I am completely confused on how to use twitter4j + app engine >> + gwt! >> >> Anyone? >> >> On Sunday, August 23, 2009, Jeune <[email protected]> wrote: >> >> > Hi all! >> >> > Has anyone of you tried using twitter4j in appengine? I am a bit stuck >> > and the code examples on their website isn't helping me very much at >> > all. I am struggling to find a way to use it using servlets etc >> > because the code examples are in a main method. >> >> > I delineate my problem more in a post I made here: >> >http://stackoverflow.com/questions/1318840/right-way-to-use-twitter4j... >> >> > Any insight would be greatly appreciated! >> >> > Thanks! > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google App Engine" 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-appengine?hl=en -~----------~----~----~----~------~----~------~--~---
