Hey,

I'm seeing the same issue kind of. We're able to set the User-Agent,
but not completely. That string is still always appended.

This is causing issues because we're using an API which authenticates
its version via User-Agent so we're getting VersionErrors due the
appended user-agent string.

     User-Agent: API_VERSION_DARTAPI_12.8.12 AppEngine-Google;
(+http://code.google.com/appengine; appid: google.com:dartapi)\r\n

Is there a way to set it completely and delete the second part?

- Avi

On Jul 21, 6:25 pm, "Ikai Lan (Google)" <[email protected]> wrote:
> Interestingly enough it says we can do it here:
>
> http://googleappengine.blogspot.com/2009/04/sdk-version-121-released....
>
> Though I wonder if we changed this to make it easier to spot spammers.
>
> Ikai Lan
> Developer Programs Engineer, Google App Engine
> Blog:http://googleappengine.blogspot.com
> Twitter:http://twitter.com/app_engine
> Reddit:http://www.reddit.com/r/appengine
>
>
>
>
>
>
>
> On Fri, Jul 15, 2011 at 2:45 AM, ANithian <[email protected]> wrote:
> > Hi all,
>
> > Apologies if I am missing something fundamental but I am not having
> > any luck setting the user agent string of my URL connection to a web
> > site I am trying to invoke.
>
> > Here is my code:
> > URL u = new URL("http://hokiesuns.appspot.com/echorequest";);
> > HttpURLConnection uConn = (HttpURLConnection)u.openConnection();
> > uConn.setRequestProperty("User-Agent", "MyAgent");
>
> > If you access that URL, it will simply print the user agent of the
> > request and I always see:
> > "AppEngine-Google; (+http://code.google.com/appengine;appid:
> > s~hokiesuns)" (Since my app is hokiesuns and I am invoking from that)
>
> > I have read that it's possible to set the user agent and I double
> > checked the spelling from the HTTP spec, am I missing something?
>
> > Thanks
> > Amit
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Google App Engine for Java" 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-java?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine for Java" 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-java?hl=en.

Reply via email to