[google-appengine] Re: Can not get authenticated By Directory API

2015-07-22 Thread 東久世高義
Thanks for the advice.

at first,we found that user cannot get administrator authenticated thorw 
the code below,
which other companies will get throw successfully.
*
   String sessionedDomain = loginPso.getDomain();
   LOGGER.info("change domain: " + sessionedDomain);
   NamespaceManager.set(sessionedDomain);
   if (service.isUserAdmin()) {
loginPso.setRole(Role.SYSTEM_ADMIN);
// license will not be check if it is the administrator

// administrator's profile will be synchronized
User systemAdmin = userLogic.selectContractor(email);
if (systemAdmin == null) {
return null;
}

*
service.isUserAdmin is false in spite of the user is  administrator.

the method "isUserAdmin"  is ↓
*
boolean com.google.appengine.api.users.UserService.isUserAdmin()

isUserAdmin
boolean isUserAdmin()
Returns true if the user making this request is an admin for this 
application, false otherwise.
Throws: 
java.lang.IllegalStateException - If the current user is not logged in.
*


then we check the page below ,found it can not be authenticated because of 
error 403
https://developers.google.com/admin-sdk/directory/v1/reference/groups/list?hl=ja

so we think may be this user can not get authenticated by Directory API.

Cheers.

2015年7月23日木曜日 0時28分13秒 UTC+9 Patrice (Cloud Platform Support):
>
> Hmm, without knowing the domain or scope or seeing your authenticating 
> code, this is not super easy to help you with this.
>
> I'd suggest trying to figure out what is different for this user's domain 
> and changing that so it matches all your other customers.
>
> Another solution would be to try and post your question on StackOverflow. 
> We do monitor that site and answer questions there, so you will get either 
> us or someone else from the community to help you out. But you'll need to 
> add some details, right now this is not really answerable, as we're lacking 
> details.
>
> Cheers!
>
> On Tuesday, July 21, 2015 at 9:09:20 PM UTC-4, 東久世高義 wrote:
>>
>> Thanks for the advice.
>>
>> We made a application with GAE.
>> So we can let  user use the app from  Company A ,B,C,...to Z under their 
>> own domain .
>> And, to use the app,user must have a Gmail account which hosting to 
>> Google.
>>
>> We do  use  Oauth2 
>>  to 
>> do the authentication .
>> And the situiton is only the Company A can not access the app.
>> Which ,the Company's administrator can not  get authenticated by 
>>  Directory API.
>>
>>
>>
>> 2015年7月22日水曜日 2時01分39秒 UTC+9 Patrice (Cloud Platform Support):
>>>
>>> Hi!
>>>
>>> I'm not 100% sure I get your issue.
>>>
>>> You are from Company B and you're trying to get information from Company 
>>> A? You'll need to authenticate using Oauth2 
>>> 
>>> .
>>>
>>> Cheers!
>>>
>>> On Tuesday, July 21, 2015 at 1:20:10 AM UTC-4, 東久世高義 wrote:

 [What we asked]
How can we get authenticated By  Directory API

 [What is now confused ]
   When we use the Directory API from GoogleApps to get account 
 informations , 
   only the company A can not  get the informations,others will be ok.

 [What we found]
   When excute this page ,we get error 403
   →
 https://developers.google.com/apis-explorer/#p/admin/directory_v1/directory.groups.list?customer=my_customer&domain=[CompanyA's
  
 domail]&_h=1& 
   →result is :
   

 403 Forbidden

 - Show headers -

 {
  "error": {
   "errors": [
{
 "domain": "global",
 "reason": "forbidden",
 "message": "Not Authorized to access this resource/api"
}
   ],
   "code": 403,
   "message": "Not Authorized to access this resource/api"
  }

 }

 [The Condition to get authenticated ]
1.The excute account is the administratror of Gmail Domain
2. GoogleApps Access is checked on  at GoogleApps console
which Company A 's account is also the same setting



-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/b8874873-8943-451a-b764-18f7a3d740c1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] cannot delete application

2015-07-22 Thread JH
I am having problems deleting one of my applications.  I get errors every 
time I disable or delete.  It says it's scheduled for deletion but never 
deletes.  I've tried many times.  If I goto the new google developer 
dashboard I get "the project you requested is unavailable".  Can someone 
from Google help delete this app?

Thanks

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/78c36044-e085-48a5-8d7a-cef6001b4aff%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Application stuck in traffic migration

2015-07-22 Thread Patrice (Cloud Platform Support)
Hi Nick,

Sorry for the lack of reply or updates. This is just to let you know you 
are not forgotten and we've tried to figure out what was happening. We now 
have a better understanding of what caused your traffic migration to stop 
and it should be fixed relatively shortly.

I'll let you know whenever I have more news on that front.

Cheers!

On Monday, July 13, 2015 at 2:17:56 PM UTC-4, Patrice (Cloud Platform 
Support) wrote:
>
> Hi Nick,
>
> thank you for the quick replies. I just double-checked and I can confirm 
> that it seems okay on our end when we check. Do you mind including a 
> screenshot of what you see so we can investigate on how come there can be a 
> discrepancy?
>
> thank you in advance.
>
> On Monday, July 13, 2015 at 10:46:51 AM UTC-4, Nick Clarey wrote:
>>
>> I'm afraid no change that I can see - still listed as "traffic move is in 
>> progress".
>>
>> Best regards,
>>
>> Nick
>>
>> On 13 July 2015 at 15:29, Patrice (Cloud Platform Support) <
>> pvoutsi...@google.com> wrote:
>>
>>> Hi Nick,
>>>
>>> We've been investigating, and it seems like it went through recently. 
>>> Can you confirm that?
>>>
>>> We're looking at a root cause, but from what we can see, you should be 
>>> done with the traffic migration.
>>>
>>> Cheers
>>>
>>>
>>> On Thursday, July 9, 2015 at 1:40:56 PM UTC-4, Nick Clarey wrote:

 Thanks Patrice, now raised as issue 12134.

 Best regards,

 Nick

 On 9 July 2015 at 17:31, Patrice (Cloud Platform Support) <
 pvoutsi...@google.com> wrote:

> Hey again Nick.
>
> This is definitely peculiar. What I would suggest at this point is to 
> open a Defect report on this page 
> , and make 
> sure to use the "Restrict-View-EditIssue" label. This way only you (the 
> creator) and people from Google will be able to see it. On that issue, 
> you 
> can then give your appID, and we will be able to go investigate further 
> and 
> see what can be done. 
>
> Cheers!
>
>
> On Thursday, July 9, 2015 at 12:05:22 PM UTC-4, Nick Clarey wrote:
>>
>> Hi Patrice,
>>
>> It's a Python app, and yes warmup requests are enabled.
>>
>> The app is stuck in the "migrating" state - the "traffic destination" 
>> has been in the "Traffic move is in progress" for 16 days. The radio 
>> buttons to change default versions are disabled so that I cannot change 
>> the 
>> default version, which is still the "traffic source".
>>
>> Best regards,
>>
>> Nick
>>
>> On 9 July 2015 at 16:58, Patrice (Cloud Platform Support) <
>> pvoutsi...@google.com> wrote:
>>
>>> Hi Nick,
>>>
>>> If your app is in Python, Go or PHP, did you enable warmup requests?
>>>
>>> If you did, then you mean the app is in a migrated state because the 
>>> new one isn't the default version yet? Or because your old version 
>>> still 
>>> serves? The older version should continue serving if your users type 
>>> the 
>>> version in your url.
>>>
>>> Cheers
>>>
>>> On Thursday, July 9, 2015 at 10:29:00 AM UTC-4, Nick Clarey wrote:

 Hi all,

 I thought I'd try using traffic migration to shift versions of my 
 appengine application, but it seems to now be jammed in the migrating 
 state. I thought I'd leave it for a while but at 16 days and counting 
 I'm 
 thinking something fishy is going on.

 Is there some way to force it to complete?

 Best regards,

 Nick

>>>  -- 
>>> You received this message because you are subscribed to a topic in 
>>> the Google Groups "Google App Engine" group.
>>> To unsubscribe from this topic, visit 
>>> https://groups.google.com/d/topic/google-appengine/pBPJ6g2WsZU/unsubscribe
>>> .
>>> To unsubscribe from this group and all its topics, send an email to 
>>> google-appengine+unsubscr...@googlegroups.com.
>>> To post to this group, send email to 
>>> google-appengine@googlegroups.com.
>>> Visit this group at http://groups.google.com/group/google-appengine.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/google-appengine/cefaf609-593f-400d-9302-f1d0e2669723%40googlegroups.com
>>>  
>>> 
>>> .
>>>
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>>
>>
>> -- 
>> Nick Clarey
>> CEO, Airsource Ltd.
>> Phone: +44-1223-708370
>> Fax : +44-1223-309814
>>  
>  -- 
> You received this message because you are subscribed to a topic in the 
> Google Groups "Google App Engine" group.
> To unsubscrib

[google-appengine] Re: Will AppEngine autoscale if current instance(s) don't have enough memory?

2015-07-22 Thread Alex Kerr
Thanks. How can we find the correct figure for memory usage and 
availability from PHP, within the App Engine environment?

For mem usage seems I can use memory_get_usage() and/or 
memory_get_peak_usage() and either with or without (true) to (from PHP 
docs) "give the real size of memory allocated from system. If not set or 
FALSE only the memory used by emalloc() is reported."

For mem availability is ini_get('memory_limit') accurate - it reports "2G" 
(I assume 2 GB?) on App Engine but that can't be right can it, I thought 
basic instances only had 128 MB?

Alex

On Wednesday, July 22, 2015 at 5:25:11 PM UTC+1, Stuart Langley wrote:
>
> That why I said "If you know deterministically" ;) At a guess I would 
> think most image manipulation operations would use a predicable amount of 
> memory for a given image size/type.
>
> However, I would suggest unless you're manipulating high quality images 
> (e.g. > 25MB in size each) you should not be overly concerned about scaling 
> based on memory usage. As others have mentioned there are soft and hard 
> memory limits - you're users would only see an error if you exceeded the 
> hard memory limit and the instance was killed. 
> For soft memory limits the instance is terminated when the requests have 
> completed.
>
>
> On Wednesday, 22 July 2015 05:50:01 UTC-7, Alex Kerr wrote:
>>
>> Thanks Stuart. That sounds good and I was starting to think along those 
>> sorts of lines.
>>
>> But how would I assess how much memory a user request uses? Are there 
>> particular PHP commands or AppEngine or Cloud Console features I could use 
>> to determine this?
>> And secondly, how do I assess how close to the instance memory limit I am 
>> (at least from the PHP perspective)?
>>
>> Currently instances seem to be a bit of a black box to me - not sure how 
>> close to resource limits I am with any particular code I run - would love 
>> any tips on determining this! (e.g. also for using VFS etc.)
>>
>> Many thanks
>>
>> On Wednesday, July 22, 2015 at 2:27:33 AM UTC+1, Stuart Langley wrote:
>>>
>>> How many users could a single instance handle concurrently before it 
>>> runs out of memory now? 
>>>
>>> If you know deterministically how much memory a user request will 
>>> require you can implement some logic in your app to slow/pause the request 
>>> processing in the instance when it is close to running out of memory. As 
>>> the request latency grows (because you're slowing requests at the instance 
>>> level) then more instances will be added to handle the users load. 
>>> Basically you just queue requests at the instance level.
>>>
>>> On Tuesday, 21 July 2015 10:48:05 UTC-7, Alex Kerr wrote:

 Thanks Patrice. Your second document refers to Python. I'm using PHP - 
 are the same options applicable to that too?

 I'm just wondering what to do when there are sufficient numbers of 
 users of my website (at any given time) to cause the running instances to 
 run out of memory. Logically, the thing to do would be to get more 
 instances fired up while the extra requests are coming in. I really need a 
 simple, automated as possible solution (hence why I'm using app engine). 
 If 
 it doesn't respond to memory usage directly, is there a way to instruct or 
 trick the App Engine autoscaler to initiate more instances (i.e. trigger 
 it 
 to do so based on some other metric)?

 Surely there has to be some alternative here to my users seeing my app 
 fail due to out of memory errors!?

 Thanks,
 Alex

 On Tuesday, July 21, 2015 at 6:37:08 PM UTC+1, Patrice (Cloud Platform 
 Support) wrote:
>
> Hi Alex,
>
> Scaling doesn't really happen based on memory, but based on latency 
> and number of requests. It's highly tied into your scaling settings 
> (either 
> manual, automatic, or basic), and which exact config you have. You can 
> lookup this document  
> that 
> contains some information on scaling, or this one 
> 
>  
> which explains the configuration you can setup (look a bit further down 
> than my link, it includes how to setup the three types of scaling and the 
> options available to you)
>
> But to answer "can we have autoscaling when an instance run out of 
> memory", not on App Engine directly. One thing you definitely can do is 
> to 
> use ManagedVMs  
> and the beta autoscaler 
> , which you can 
> set to "target utilization level" based on CPU utilization 
> 
> .
>
> Since app engine scales a bit differently, there is definite

[google-appengine] Re: gms.StatusHelper Status from wire: INVALID_KEY status: null

2015-07-22 Thread Nick (Cloud Platform Support)
Hi 水晶 ,

Google Groups isn't the place to post specific technical issues, as this 
forum is meant more for general discussion of the platform and services. 

If you would like help with a technical issue, you should post to 
stackoverflow [1] or serverfault [2]. 

If you believe you've identified and can reproduce an issue with the 
platform itself (behaviour is different from documentation or error occurs 
during normal use), then you should proceed to open a public issue tracker 
[3] issue with enough detail to reproduce the issue on our side, or if 
possible, an attached app that can be used to directly observe the 
behaviour. 

Your issue report contains not enough information to determine what is 
happening, even if you did post it to one of those other locations, so I 
suggest adding more detail before doing so. That detail could include:

* What code is causing this method call?
* What in general is happening in your app?

If you would like to open a thread in this forum discussing the platform or 
services in more broad terms, starting a discussion that would be useful 
for other users to join in to, feel free to do so.

Have a great day!

[1] http://www.stackoverflow.com/
[2] http://www.serverfault.com/
[3] http://code.google.com/p/google-appengine/issues/list

On Wednesday, July 22, 2015 at 9:45:54 AM UTC+3, 水晶 wrote:
>
> Recently, I got this error, when android app access GAE API. It worked 
> before, and I don't change anything.
>
> 07-22 13:42:28.786: I/GLSUser(1569): [GLSUser] 
> getAuthtoken(, oauth2:
> https://www.googleapis.com/auth/userinfo.email 
> https://www.googleapis.com/auth/calendar) -> status: UNKNOWN)
> 07-22 13:42:28.786: I/GLSUser(1569): [GLSUser] Extracting token using key: 
> Auth
> gms.StatusHelper Status from wire: INVALID_KEY status: null
> 07-22 13:42:28.786: W/System.err(19213): 
> com.google.api.client.googleapis.extensions.android.gms.auth.GoogleAuthIOException
> 07-22 13:42:28.796: W/System.err(19213): at 
> com.google.api.client.googleapis.extensions.android.gms.auth.GoogleAccountCredential$RequestHandler.intercept(GoogleAccountCredential.java:308)
> 07-22 13:42:28.796: W/System.err(19213): at 
> com.google.api.client.http.HttpRequest.execute(HttpRequest.java:854)
> 07-22 13:42:28.796: W/System.err(19213): at 
> com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:410)
> 07-22 13:42:28.796: W/System.err(19213): at 
> com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:343)
> 07-22 13:42:28.796: W/System.err(19213): at 
> com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:460)
> 07-22 13:42:28.796: W/System.err(19213): at 
> com.viziner.cleaninghouse.api.APIAsyncTask.doInBackground(APIAsyncTask.java:312)
> 07-22 13:42:28.796: W/System.err(19213): at 
> com.viziner.cleaninghouse.api.APITask.doInBackground(APITask.java:1)
> 07-22 13:42:28.796: W/System.err(19213): at 
> android.os.AsyncTask$2.call(AsyncTask.java:288)
> 07-22 13:42:28.796: W/System.err(19213): at 
> java.util.concurrent.FutureTask.run(FutureTask.java:237)
> 07-22 13:42:28.796: W/System.err(19213): at 
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)
> 07-22 13:42:28.796: W/System.err(19213): at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)
> 07-22 13:42:28.796: W/System.err(19213): at 
> java.lang.Thread.run(Thread.java:818)
>
> Anyone can help me?
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/71c7377b-6166-4333-96de-215bada11ce1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Will AppEngine autoscale if current instance(s) don't have enough memory?

2015-07-22 Thread Stuart Langley
That why I said "If you know deterministically" ;) At a guess I would think 
most image manipulation operations would use a predicable amount of memory 
for a given image size/type.

However, I would suggest unless you're manipulating high quality images 
(e.g. > 25MB in size each) you should not be overly concerned about scaling 
based on memory usage. As others have mentioned there are soft and hard 
memory limits - you're users would only see an error if you exceeded the 
hard memory limit and the instance was killed. 
For soft memory limits the instance is terminated when the requests have 
completed.


On Wednesday, 22 July 2015 05:50:01 UTC-7, Alex Kerr wrote:
>
> Thanks Stuart. That sounds good and I was starting to think along those 
> sorts of lines.
>
> But how would I assess how much memory a user request uses? Are there 
> particular PHP commands or AppEngine or Cloud Console features I could use 
> to determine this?
> And secondly, how do I assess how close to the instance memory limit I am 
> (at least from the PHP perspective)?
>
> Currently instances seem to be a bit of a black box to me - not sure how 
> close to resource limits I am with any particular code I run - would love 
> any tips on determining this! (e.g. also for using VFS etc.)
>
> Many thanks
>
> On Wednesday, July 22, 2015 at 2:27:33 AM UTC+1, Stuart Langley wrote:
>>
>> How many users could a single instance handle concurrently before it runs 
>> out of memory now? 
>>
>> If you know deterministically how much memory a user request will require 
>> you can implement some logic in your app to slow/pause the request 
>> processing in the instance when it is close to running out of memory. As 
>> the request latency grows (because you're slowing requests at the instance 
>> level) then more instances will be added to handle the users load. 
>> Basically you just queue requests at the instance level.
>>
>> On Tuesday, 21 July 2015 10:48:05 UTC-7, Alex Kerr wrote:
>>>
>>> Thanks Patrice. Your second document refers to Python. I'm using PHP - 
>>> are the same options applicable to that too?
>>>
>>> I'm just wondering what to do when there are sufficient numbers of users 
>>> of my website (at any given time) to cause the running instances to run out 
>>> of memory. Logically, the thing to do would be to get more instances fired 
>>> up while the extra requests are coming in. I really need a simple, 
>>> automated as possible solution (hence why I'm using app engine). If it 
>>> doesn't respond to memory usage directly, is there a way to instruct or 
>>> trick the App Engine autoscaler to initiate more instances (i.e. trigger it 
>>> to do so based on some other metric)?
>>>
>>> Surely there has to be some alternative here to my users seeing my app 
>>> fail due to out of memory errors!?
>>>
>>> Thanks,
>>> Alex
>>>
>>> On Tuesday, July 21, 2015 at 6:37:08 PM UTC+1, Patrice (Cloud Platform 
>>> Support) wrote:

 Hi Alex,

 Scaling doesn't really happen based on memory, but based on latency and 
 number of requests. It's highly tied into your scaling settings (either 
 manual, automatic, or basic), and which exact config you have. You can 
 lookup this document  
 that 
 contains some information on scaling, or this one 
 
  
 which explains the configuration you can setup (look a bit further down 
 than my link, it includes how to setup the three types of scaling and the 
 options available to you)

 But to answer "can we have autoscaling when an instance run out of 
 memory", not on App Engine directly. One thing you definitely can do is to 
 use ManagedVMs  
 and the beta autoscaler 
 , which you can set 
 to "target utilization level" based on CPU utilization 
 
 .

 Since app engine scales a bit differently, there is definitely a way to 
 do it, but it would be a workaround that would be way more involved than 
 simply switching to ManagedVMs, so I wouldn't recommend it, as it would be 
 clunky, might degrade customer experience (by making your whole app a tad 
 slower).

 Cheers!

 On Monday, July 20, 2015 at 4:07:05 PM UTC-4, Alex Kerr wrote:
>
> Hi,
>
> I've got a PHP app running in standard AppEngine. It does use a bit of 
> memory for in-app image manipulation. I'm wondering what happens when 
> there 
> are enough concurrent users of my web app that the current instance(s) 
> don't have the memory to handle more users (i.e. so it's not a CPU load 
> issue, or other things (?) that might cause the app to scale

[google-appengine] Re: Rate Limit Exceeded when creating new project through devloper's console

2015-07-22 Thread Allen Polak
FYI, not sure if this is the same issue or not, but it seems related:

https://code.google.com/p/googleappengine/issues/detail?id=12167

I'll try again in a few hours to see if I experience the same fix as well.

On Thursday, July 9, 2015 at 7:58:20 PM UTC-4, Nick (Cloud Platform 
Support) wrote:
>
> Hey Phil,
>
> This forum isn't generally meant for 1-on-1 technical support, but I 
> recognize that you don't really have enough info or enough ideas of next 
> steps in order to create a good stackoverflow question or public issue 
> tracker issue. That being the case, why don't you go ahead and capture a HAR 
> recording  of your 
> attempt at creating the project, and see if you can use the HAR analyzer to 
> see any extra error detail in HTTP responses. If you manage to find enough 
> information to determine the issue, or even if you can just produce the HAR 
> file, create a public issue tracker issue 
>  with that 
> attached, set it to "Type-Production", and post the link here so that I can 
> follow up with you. While we don't do 1-on-1 technical support here, if 
> you've noticed a problem with the platform itself, we definitely want to 
> help fix that.
>
> Finally, it's possible the rate-limiting response is perfectly normal and 
> you're attempting to create projects at a fast rate (it seems you'd be 
> aware of that, though). So, that's something to consider.
>
> Anyways, let me know how it goes, and I'll be able to advise you on next 
> steps,
>
> Best wishes,
>
> Nick
>
> On Thursday, July 9, 2015 at 9:20:36 AM UTC-4, Phil Side wrote:
>>
>>
>> I'm getting the message "Rate Limit Exceeded" when I try to create a new 
>> project through the developer's console. I have no idea what rate it is 
>> referring to, and so no idea how to fix the problem. Any help would be 
>> appreciated. 
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/5d5243da-0ff9-4ccf-b31f-1af752f6293f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Can not get authenticated By Directory API

2015-07-22 Thread Patrice (Cloud Platform Support)
Hmm, without knowing the domain or scope or seeing your authenticating 
code, this is not super easy to help you with this.

I'd suggest trying to figure out what is different for this user's domain 
and changing that so it matches all your other customers.

Another solution would be to try and post your question on StackOverflow. 
We do monitor that site and answer questions there, so you will get either 
us or someone else from the community to help you out. But you'll need to 
add some details, right now this is not really answerable, as we're lacking 
details.

Cheers!

On Tuesday, July 21, 2015 at 9:09:20 PM UTC-4, 東久世高義 wrote:
>
> Thanks for the advice.
>
> We made a application with GAE.
> So we can let  user use the app from  Company A ,B,C,...to Z under their 
> own domain .
> And, to use the app,user must have a Gmail account which hosting to Google.
>
> We do  use  Oauth2 
>  to 
> do the authentication .
> And the situiton is only the Company A can not access the app.
> Which ,the Company's administrator can not  get authenticated by 
>  Directory API.
>
>
>
> 2015年7月22日水曜日 2時01分39秒 UTC+9 Patrice (Cloud Platform Support):
>>
>> Hi!
>>
>> I'm not 100% sure I get your issue.
>>
>> You are from Company B and you're trying to get information from Company 
>> A? You'll need to authenticate using Oauth2 
>> 
>> .
>>
>> Cheers!
>>
>> On Tuesday, July 21, 2015 at 1:20:10 AM UTC-4, 東久世高義 wrote:
>>>
>>> [What we asked]
>>>How can we get authenticated By  Directory API
>>>
>>> [What is now confused ]
>>>   When we use the Directory API from GoogleApps to get account 
>>> informations , 
>>>   only the company A can not  get the informations,others will be ok.
>>>
>>> [What we found]
>>>   When excute this page ,we get error 403
>>>   →
>>> https://developers.google.com/apis-explorer/#p/admin/directory_v1/directory.groups.list?customer=my_customer&domain=[CompanyA's
>>>  
>>> domail]&_h=1& 
>>>   →result is :
>>>   
>>>
>>> 403 Forbidden
>>>
>>> - Show headers -
>>>
>>> {
>>>  "error": {
>>>   "errors": [
>>>{
>>> "domain": "global",
>>> "reason": "forbidden",
>>> "message": "Not Authorized to access this resource/api"
>>>}
>>>   ],
>>>   "code": 403,
>>>   "message": "Not Authorized to access this resource/api"
>>>  }
>>>
>>> }
>>>
>>> [The Condition to get authenticated ]
>>>1.The excute account is the administratror of Gmail Domain
>>>2. GoogleApps Access is checked on  at GoogleApps console
>>>which Company A 's account is also the same setting
>>>
>>>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/f6014da7-b238-47c9-86eb-2b83d1763129%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Cron - targeting a particular version of a particular module

2015-07-22 Thread Paul Canning
Wait, I got it. You can target the versions using the format:

version-dot-module

e.g. 1-5-dot-main-module

On Wednesday, July 22, 2015 at 3:53:36 PM UTC+1, Paul Canning wrote:
>
> I am facing a similar issue.
>
> Firstly, how do you target a specific version of a module in the 
> dispatch.yaml? The docs only talk about modules.
>
> Secondly, is there anyway to use more then 10 dispatch rules? I have 
> already had to use 5 for routing subdomains (unless there is another way to 
> achieve this?)
>
> On Tuesday, April 7, 2015 at 6:55:29 PM UTC+1, Shobhit wrote:
>>
>> Hi Dawid.
>>
>> First thing in cron.yaml, you are supposed to use version or module in 
>> the target parameter. If you wish to target the cron job for a particular 
>> version and module you can use the dispatch.yaml as described by Vinny in 
>> the previous messages.
>>
>> On Thursday, February 20, 2014 at 12:29:04 PM UTC-5, Dawid wrote:
>>>
>>> Hi all,
>>>
>>> How can have a cron job target a particular version of a particular 
>>> module? I've tried:
>>> *target: version.module*
>>>
>>> Unfortunately, appcfg.py won't accept it:
>>> *Unable to assign value 'debug.reports' to attribute 'target':*
>>> *Value 'debug.reports' for target does not match expression 
>>> '^(?:^(?:(?:((?!-)[a-z\d\-]{1,63}):)?)((?!-)[a-z\d\-]{1,100})$)$'*
>>> *  in "./cron.yaml", line 34, column 11*
>>>
>>> Many thanks,
>>> Dawid
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/f6077981-8696-43e3-9262-db8eccbf7d8f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Cron - targeting a particular version of a particular module

2015-07-22 Thread Paul Canning
I am facing a similar issue.

Firstly, how do you target a specific version of a module in the 
dispatch.yaml? The docs only talk about modules.

Secondly, is there anyway to use more then 10 dispatch rules? I have 
already had to use 5 for routing subdomains (unless there is another way to 
achieve this?)

On Tuesday, April 7, 2015 at 6:55:29 PM UTC+1, Shobhit wrote:
>
> Hi Dawid.
>
> First thing in cron.yaml, you are supposed to use version or module in the 
> target parameter. If you wish to target the cron job for a particular 
> version and module you can use the dispatch.yaml as described by Vinny in 
> the previous messages.
>
> On Thursday, February 20, 2014 at 12:29:04 PM UTC-5, Dawid wrote:
>>
>> Hi all,
>>
>> How can have a cron job target a particular version of a particular 
>> module? I've tried:
>> *target: version.module*
>>
>> Unfortunately, appcfg.py won't accept it:
>> *Unable to assign value 'debug.reports' to attribute 'target':*
>> *Value 'debug.reports' for target does not match expression 
>> '^(?:^(?:(?:((?!-)[a-z\d\-]{1,63}):)?)((?!-)[a-z\d\-]{1,100})$)$'*
>> *  in "./cron.yaml", line 34, column 11*
>>
>> Many thanks,
>> Dawid
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/744146ed-8d8f-45ae-b97f-59142a21fc8f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Google IDs produced by the Users service seem to differ from those produced by OAuth2

2015-07-22 Thread tempy
Hi Nick,

Thanks for the reply. I guess then my question is if there is any way to 
map the general Google account ID to the corresponding App Engine one. I'm 
definitely willing to run a conversion API from inside the GAE sandbox for 
this purpose, but I have no idea how to do the mapping even within GAE.

Thanks!

On Thursday, July 9, 2015 at 2:09:26 AM UTC+2, Nick (Cloud Platform 
Support) wrote:
>
> Hey tempy,
>
> This ID value is unique to the Google App Engine Users service, and won't 
> be the same as your general Google account ID. You can view the difference 
> between the two ID values by playing around with 
> http://gae-login-explainer.appspot.com/, which also explains the main 
> differences between the Google sign-in for websites button and App Engine 
> login URL methods of authentication. 
>
> Let me know if you've got any questions, and I'll do my best to help 
> clarify.
>
> On Sunday, July 5, 2015 at 2:07:53 PM UTC-4, tempy wrote:
>>
>> I have a production app on GAE that's been running for a while. I've been 
>> using the Users service for authentication, and my user entities in the 
>> datastore hold on to the unique account ID provided by the users service. 
>> Now, I want to bolt on some new functionality that will live outside of the 
>> GAE environment, but which also needs to authenticate to the existing GAE 
>> app. I've tried to do this with standard OAuth2 (as described here: 
>> https://developers.google.com/identity/sign-in/web/), but it seems that 
>> the Google IDs that are given out by OAuth2 are not the same for a given 
>> user when they login through the Users service on GAE vs regular OAuth2. 
>> Specifically, the Oauth2 produces a JWT which unpacks to something like:
>>
>> {
>>> iss: "accounts.google.com",
>>> sub: "100768731291047440489",
>>> azp: "
>>> 995713799104-tn1tj3qj8l4h1rhu0sucpb6aormqekls.apps.googleusercontent.com
>>> ",
>>> email: "john...@googlemail.com ",
>>> at_hash: "PKaCDQBHNPH5HTbRXuAcEw",
>>> email_verified: "true"
>>>
>>>- ...
>>>
>>>
>>>- }
>>>
>>>
>> The sub value in that response should contain the user's unique ID, but 
>> it doesn't match that of the Users API. So, am I missing something or is it 
>> the case that Google's IDs are only available within the context of the 
>> users service and differ outside of it? If this is indeed the case, is 
>> there any way to translate from one sort of ID to the other?
>>
>> Many thanks,
>> mike 
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/d2a157bb-c886-4dcf-a236-1f3e8d9902aa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Error creating Cloud Storage default bucket for AppEngine app

2015-07-22 Thread Patrice (Cloud Platform Support)
Hi Nicolo,

We've had a report about this a week ago actually. Is it possible the steps 
highlighted here 
 help you 
out?

Let me know if they don't so we can look at other options.

Cheers!

On Wednesday, July 22, 2015 at 4:06:23 AM UTC-4, Nicolo' Canali De Rossi 
wrote:
>
> Hello
>
> I was trying to set up a default bucket for Cloud Storage as described 
> here 
> https://cloud.google.com/appengine/docs/python/googlecloudstorageclient/activate
>
> Unfortunately, after pressing the Create button  in the Cloud Integration 
> section in the AppEngine console, an error is returned:
>
> An error occurred when creating the project. Please retry. (Screenshot 
> attached)
>
> Has anyone experienced this and fixed it? I found only one SO thread but 
> not really helpful...
>
>
> Thanks a lot
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/52b8516c-a199-44c5-84aa-4db49d7f2166%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: Will AppEngine autoscale if current instance(s) don't have enough memory?

2015-07-22 Thread Alex Kerr
Thanks Stuart. That sounds good and I was starting to think along those 
sorts of lines.

But how would I assess how much memory a user request uses? Are there 
particular PHP commands or AppEngine or Cloud Console features I could use 
to determine this?
And secondly, how do I assess how close to the instance memory limit I am 
(at least from the PHP perspective)?

Currently instances seem to be a bit of a black box to me - not sure how 
close to resource limits I am with any particular code I run - would love 
any tips on determining this! (e.g. also for using VFS etc.)

Many thanks

On Wednesday, July 22, 2015 at 2:27:33 AM UTC+1, Stuart Langley wrote:
>
> How many users could a single instance handle concurrently before it runs 
> out of memory now? 
>
> If you know deterministically how much memory a user request will require 
> you can implement some logic in your app to slow/pause the request 
> processing in the instance when it is close to running out of memory. As 
> the request latency grows (because you're slowing requests at the instance 
> level) then more instances will be added to handle the users load. 
> Basically you just queue requests at the instance level.
>
> On Tuesday, 21 July 2015 10:48:05 UTC-7, Alex Kerr wrote:
>>
>> Thanks Patrice. Your second document refers to Python. I'm using PHP - 
>> are the same options applicable to that too?
>>
>> I'm just wondering what to do when there are sufficient numbers of users 
>> of my website (at any given time) to cause the running instances to run out 
>> of memory. Logically, the thing to do would be to get more instances fired 
>> up while the extra requests are coming in. I really need a simple, 
>> automated as possible solution (hence why I'm using app engine). If it 
>> doesn't respond to memory usage directly, is there a way to instruct or 
>> trick the App Engine autoscaler to initiate more instances (i.e. trigger it 
>> to do so based on some other metric)?
>>
>> Surely there has to be some alternative here to my users seeing my app 
>> fail due to out of memory errors!?
>>
>> Thanks,
>> Alex
>>
>> On Tuesday, July 21, 2015 at 6:37:08 PM UTC+1, Patrice (Cloud Platform 
>> Support) wrote:
>>>
>>> Hi Alex,
>>>
>>> Scaling doesn't really happen based on memory, but based on latency and 
>>> number of requests. It's highly tied into your scaling settings (either 
>>> manual, automatic, or basic), and which exact config you have. You can 
>>> lookup this document  that 
>>> contains some information on scaling, or this one 
>>> 
>>>  
>>> which explains the configuration you can setup (look a bit further down 
>>> than my link, it includes how to setup the three types of scaling and the 
>>> options available to you)
>>>
>>> But to answer "can we have autoscaling when an instance run out of 
>>> memory", not on App Engine directly. One thing you definitely can do is to 
>>> use ManagedVMs  
>>> and the beta autoscaler 
>>> , which you can set 
>>> to "target utilization level" based on CPU utilization 
>>> 
>>> .
>>>
>>> Since app engine scales a bit differently, there is definitely a way to 
>>> do it, but it would be a workaround that would be way more involved than 
>>> simply switching to ManagedVMs, so I wouldn't recommend it, as it would be 
>>> clunky, might degrade customer experience (by making your whole app a tad 
>>> slower).
>>>
>>> Cheers!
>>>
>>> On Monday, July 20, 2015 at 4:07:05 PM UTC-4, Alex Kerr wrote:

 Hi,

 I've got a PHP app running in standard AppEngine. It does use a bit of 
 memory for in-app image manipulation. I'm wondering what happens when 
 there 
 are enough concurrent users of my web app that the current instance(s) 
 don't have the memory to handle more users (i.e. so it's not a CPU load 
 issue, or other things (?) that might cause the app to scale). I don't 
 want 
 the users to see errors or a non-working app, I just want the AppEngine 
 autoscaler to add another instance(s).

 Is this how things work? If not, is there a way to get autoscaling to 
 happen on the basis of current instances running out of memory?

 Many thanks!
 Alex

>>>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d

[google-appengine] Re: Will AppEngine autoscale if current instance(s) don't have enough memory?

2015-07-22 Thread Tapir
I have a Java GAE project on F1 instances. 
Its instances use more than 200M memory at most time.
Google never close these instances. :)

BTW, the memory consumption will be much smaller by using Golang.
I'm porting this Java project to Golang now.


On Tuesday, July 21, 2015 at 4:07:05 AM UTC+8, Alex Kerr wrote:
>
> Hi,
>
> I've got a PHP app running in standard AppEngine. It does use a bit of 
> memory for in-app image manipulation. I'm wondering what happens when there 
> are enough concurrent users of my web app that the current instance(s) 
> don't have the memory to handle more users (i.e. so it's not a CPU load 
> issue, or other things (?) that might cause the app to scale). I don't want 
> the users to see errors or a non-working app, I just want the AppEngine 
> autoscaler to add another instance(s).
>
> Is this how things work? If not, is there a way to get autoscaling to 
> happen on the basis of current instances running out of memory?
>
> Many thanks!
> Alex
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/ba8e4167-cbf9-4252-8a04-22c5cec94c0a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Error creating Cloud Storage default bucket for AppEngine app

2015-07-22 Thread Nicolo' Canali De Rossi
Hello

I was trying to set up a default bucket for Cloud Storage as described 
here 
https://cloud.google.com/appengine/docs/python/googlecloudstorageclient/activate

Unfortunately, after pressing the Create button  in the Cloud Integration 
section in the AppEngine console, an error is returned:

An error occurred when creating the project. Please retry. (Screenshot 
attached)

Has anyone experienced this and fixed it? I found only one SO thread but 
not really helpful...


Thanks a lot


-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/1befa4e5-04d6-4bca-ab0d-25d6550196df%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.