If I'm running my App Engine app on localhost, will I not see a value for X-AppEngine-Country?
According to the Release Notes:
All user request have an X-AppEngine-Country header which contains the ISO-3166-1开发者_如何学JAVA alpha-2 country code for the user, based on the IP address of the client request.
My app is running on localhost with the 1.5.1 Java release which contains the X-AppEngine-Country
header but I don't seem to be receiving any value for this header in my requests.
Do I have to deploy the app to a production instance to test this feature?
Yes. Geolocation is provided by an internal Google service, which isn't available in the development environment.
精彩评论