[google-appengine] How to drop a request?

2017-01-20 Thread sophie
My Python application receives a lot of unfriendly requests.  The faster 
the response will be sent the sooner I get a new request. Is it possible, 
in some cases, do not send a response (black hole mode)?

-- 
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 https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/5e589ab7-fb3a-49d1-a208-8d8c4d76c73d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: NDB dictionary

2017-01-20 Thread Richard Cheesmar
use a pre put hook to do your checking:

class Fruit(ndb.Model):
name = ndb.StringProperty(required=True)

 color = ndb.StringProperty(required=True)
 taste = ndb.StringProperty(required=True)



def _pre_put_hook(self):


On Thursday, January 19, 2017 at 5:39:56 AM UTC+2, Ryan Ang Wei En wrote:
>
> I have this sample json of a list of "Fruit":
> {
>   "apple":{
> "color":red"
> "taste":"sweet"
>   }
>   "pineapple":{
> "color":yellow"
> "taste":"sour"
>   }
> }
> I want to use a very object oriented approach to retrieve a property of my 
> entity using a string key.
> The requirements:
> 1) NDB must not be able to store any "Fruit" without the "color" or 
> "taste" fields. (JsonProperty does not meet this requirement)
> 2) "apple" and "pineapple" are unique identifiers, used to retrieve it's 
> corresponding fruit data, NDB must not be able to store multiple fruit 
> objects containing the same unique identifier.
>
> class Fruit(ndb.Model):
>   name = ndb.StringProperty(required=True)
>   color = ndb.StringProperty(required=True)
>   taste = ndb.StringProperty(required=True)
>
> class Person(ndb.Model):
>   favoritefruits = ndb.StructuredProperty(required=True,repeated=true)
>
> Then to find apple,
> person = Person.get_by_id("Johnathan").favouritefruits
> for fruit in person.favoritefruits:
>   if fruit.name == "apple"
> # found apple!
>
> The problem:
> Multiple "Fruit" objects containing the same "name" property can exist in 
> the "favoritefruits" property.
>
> What solutions are there that will fulfil both requirements 1) and 2)?
>

-- 
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 https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/bd86b6c3-bbb3-481a-a9cf-a57956f2baee%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] Re: GAE custom domain redirect from naked to www

2017-01-20 Thread 'George (Cloud Platform Support)' via Google App Engine
Hello Dev, 

You need a CNAME certificate that specifies redirecting your Root Domain to 
a sub-domain. Have you examined your certificate to make sure this is 
specified there, as desired? 

-- 
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 https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/0e81bd84-5837-458b-aaa5-41ffb2332719%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[google-appengine] App binary too big

2017-01-20 Thread Stani M
Would it be possible to raise the maximum binary size for a project? I run 
into this problem and can't remove code:

App binary too big: 35722784 > 33554432
--- end server output ---
11:46 PM Rolling back the update.
Error 422: --- begin server output ---

Kind regards,
Stani

-- 
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 https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/56deeb2c-cecf-4f18-b7bd-7ba9072dbf53%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [google-appengine] Re: Installing a linux package for app engine instance, how to?

2017-01-20 Thread 'Justin Beckwith' via Google App Engine
We should be able to get your custom domain set up for you on env:flex.
Lorne (cc'd) should be able to help us out here :)

On Thu, Jan 19, 2017 at 4:44 PM, Pub Lift <*@publift.com> wrote:

> ERROR: (gcloud.app.deploy) An error occurred while parsing file: [/home/
> adcruz/Documents/Publift/dashboard/app.yaml]
> No URLMap entries found in application configuration
>
>
>
> And I do not want to use
> env: flex
>
> either for the time being because it doesn't seem to want to use our
> custom domain
>
> On Friday, January 20, 2017 at 11:40:38 AM UTC+11, Justin Beckwith wrote:
>>
>> Could you delete the line that says "vm: true" and try again?
>>
>>
>>
>> On Tuesday, January 17, 2017 at 2:38:05 PM UTC-8, Pub Lift wrote:
>>>
>>> Hello!
>>>
>>> I'm having a bit of an issue with my app. I'm using nodejs and it
>>> interacts with gnuplot, but I'm not sure how to install the gnuplot package
>>> after deploying the app.
>>>
>>> Am I doing this right?
>>> Dockerfile
>>> FROM gcr.io/google_appengine/nodejs
>>>
>>>
>>> RUN apt-get -qq update && apt-get -qq -y install gnuplot
>>>
>>> app.yaml
>>> runtime: custom
>>> env: flex
>>> vm: true
>>>
>>> # Temporary setting to keep gcloud from uploading node_modules
>>> skip_files:
>>>  - ^node_modules$
>>>
>>>
>>> manual_scaling:
>>>   instances: 1
>>>
>>> When I run
>>> gcloud app deploy
>>>
>>> , the console just stays stuck on
>>> Building and pushing image for service [default]
>>>
>>> Can anyone tell me what I'm possibly doing wrong? Thanks!
>>>
>> --
> 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/gQhFggScNPM/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 https://groups.google.com/group/google-appengine.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-appengine/861b893c-8b55-4270-a6fd-
> 9e800dbbca52%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 

Justin Beckwith | Google Cloud Platform | @justinbeckwith
 | http://jbeckwith.com

-- 
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 https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CADd%3D1Q2hqu4%2BrZ7H0T_jOp2fgOHjDQksKH%2BGF0UhsYSOK7ZXvA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.