Live data from Hacker News

Python 3 is now available on App Engine standard environment

cloud.google.com

71–80 of 84 posts

Re: Python 3 is now available on App Engine standard environment

#72

Earlier quoted context omitted.

AFAIK you can't run a gRPC server on App Engine, but you can access other gRPC services (like all the GCP APIs) as a client. I might be wrong about the server part. All those things you mentioned in the edit should be supported in the new runtime. Edit: I see what you mean. The deeply integrated services are removed in favor of more portable solutions, like Logging moving to Stackdriver Logging (though stdout is stil…

Thanks for the reply. Yeah I'm bummed about that because id rather use GRPC client libraries for my apps than the endpoints discovery doc generated ones. Also according to this they are not supported directly anymore except logging might still work but the wording is unclear. https://cloud.google.com/appengine/docs/standard/python3/pyt... .

That page mentions that it supports the google-cloud-python libraries, which are the primary GCP gRPC client libraries for Python. The Apiary service-discovery library you are referring to is called google-api. The new GAE version doesn't support the old GAE-only libraries, like memcache, datastore, etc. These older services only worked with GAE, and therefore weren't portable to other services, which they are in the process of replacing. If I recall, the old version didn't support the google-cloud-python libraries either, so it's good to see that they are moving in that direction. I could be wrong about that though.

In short, it looks like you have access to the main GCP gRPC libraries. You don't have access to the GAE-only service libraries.

Disclaimer: was former GCP customer support.

Re: Python 3 is now available on App Engine standard environment

#73

Earlier quoted context omitted.

Long story short: security is hard. Launching these new unmodified Second Generation runtimes required us to develop new security and isolation technology (based on gVisor [1]). This allows us to securely run arbitrary code on shared data centers with isolation guarantees. This took us significantly longer than expected. The good news is, now that we have this new stack in place, we should be able to deliver runtime…

In case anyone else is wondering why you'd not just use LXC: https://cloud.google.com/blog/products/gcp/open-sourcing-gvi... That said, they don't quite go into the details of what type of isolation is missing from standard containers - I'm curious. It does seem like it would have been ideal for everyone if LXC would have had better isolation, rather than having to run a userspace kernel emulator thingy for each cont…

I work on gVisor. The answer is that having a separate kernel is required to achieve a high degree of isolation and by definition Linux containers share a kernel with the host. A separate Linux kernel could work as well, but gVisor tries to achieve a different set of trade-offs.

Re: Python 3 is now available on App Engine standard environment

#74

Earlier quoted context omitted.

AFAIK you can't run a gRPC server on App Engine, but you can access other gRPC services (like all the GCP APIs) as a client. I might be wrong about the server part. All those things you mentioned in the edit should be supported in the new runtime. Edit: I see what you mean. The deeply integrated services are removed in favor of more portable solutions, like Logging moving to Stackdriver Logging (though stdout is stil…

Thanks for the reply. Yeah I'm bummed about that because id rather use GRPC client libraries for my apps than the endpoints discovery doc generated ones. Also according to this they are not supported directly anymore except logging might still work but the wording is unclear. https://cloud.google.com/appengine/docs/standard/python3/pyt... .

The Google Cloud client libraries [1] are fully supported. You can use these to access services like Datastore, Spanner, Natural Language, and many other Cloud services. They work on this new runtime, on the flexible environment, on a VM, your local machine, etc. In my opinion, this is the most Pythonic way to integrate Cloud services in your app while maintaining portability.

[1] https://github.com/GoogleCloudPlatform/google-cloud-python -- small caveat, the repo currently states that they're not supported on App Engine standard environment. That will be updated soon to clarify that the Python 3.7 runtime on the standard environment is supported.

Re: Python 3 is now available on App Engine standard environment

#75
post #69

We're a SaaS platform running on App Engine and were part of the early-access program. Porting over our Python 3 based platform from App Engine Flex to AE Standard took just a few hours - only tweaks needed were to the YAML config files and rewrite our deployment scripts after creating a new environment and project. We still maintain a docker-based environment on AWS EBS which we were able to port over as well. Overa…

Just curious, why did you migrate from Flex to Standard? Only for the 10X price/performance boost for infrequently accessed services? PS: Regarding automagically handling spikes I have a warning that might be useful for you. The way AE load balancer works is that it: 0. A request comes. 1. AE checks for available instance. If none available: 2. Spins up new instance. 3. !!! Assigns the request to that instance. 4. Wa…

This should be a little better now: https://cloudplatform.googleblog.com/2018/05/Increase-perfor...

But yeah, you should definitely do your own load testing. GKE or Flex are probably better choices if you need more control.

(I work for GCP)

Re: Python 3 is now available on App Engine standard environment

#76
post #70

Earlier quoted context omitted.

It seems to me this product is mainly targeted at 1) new customers, and 2) AE Flex customers wanting to switch to Standard. The third category (Existing 2.7 Standard customers wanting to just upgrade to 3.7 -- which is me unfortunately) are going to be disappointed and stuck in a hard place, I think.

What would be the incentive to migrate from AE Flexible to Standard if these apis are not there? The only thing I can think of is scale to 0.

Scale to 0, faster scaling up/down (no need for full VM spin up), faster deployments, less surface area for attack (maybe?).

Re: Python 3 is now available on App Engine standard environment

#77
post #69

We're a SaaS platform running on App Engine and were part of the early-access program. Porting over our Python 3 based platform from App Engine Flex to AE Standard took just a few hours - only tweaks needed were to the YAML config files and rewrite our deployment scripts after creating a new environment and project. We still maintain a docker-based environment on AWS EBS which we were able to port over as well. Overa…

Just curious, why did you migrate from Flex to Standard? Only for the 10X price/performance boost for infrequently accessed services? PS: Regarding automagically handling spikes I have a warning that might be useful for you. The way AE load balancer works is that it: 0. A request comes. 1. AE checks for available instance. If none available: 2. Spins up new instance. 3. !!! Assigns the request to that instance. 4. Wa…

> Only for the 10X price/performance boost for infrequently accessed services?

Yes. this will allow us to offload async tasks & other non-critical tasks to standard. It will also allow us to keep lots of various staging environments available for testing / unit testing, and deploy dedicated instances that are fully contained without 24/7 costs for each instance.

Re - latency - absolutely, we've seen times where it can take 10-15 seconds to serve an initial request. Things are snappy afterwards.

Re: Python 3 is now available on App Engine standard environment

#78

Hi all, Product Manager for App Engine here. Happy to answer any questions about Python 3 on the App Engine standard environment.

Is GRPC supported? My gut feelign is no, but I hope I am wrong Edit: Holy shit this is so bittersweet. I was relying heavily on the batteries included user management, logging, admin only handlers, and especially the super easy cron job definitions. IDK what to think about this. It kinda takes away all the things that made App Engine worth it for me as a programmer who doesnt want to do dev ops.

[deleted]

Re: Python 3 is now available on App Engine standard environment

#79

Hi all, Product Manager for App Engine here. Happy to answer any questions about Python 3 on the App Engine standard environment.

Nice launch! I have some Python code which I've been meaning to convert to App Engine standard to take advantage of the free tier, and I hadn't yet adapted it to the proprietary APIs. Now I don't have to. Thanks!

One Q: Does Google Cloud IAP work with this as an option for user auth? Would one follow the App Engine flexible environment pattern in their docs? The Cloud IAP docs still mention the Users API as the recommended approach for the App Engine standard environment without an exception for the Python 3.7 runtime.

Re: Python 3 is now available on App Engine standard environment

#80

Hi all, Product Manager for App Engine here. Happy to answer any questions about Python 3 on the App Engine standard environment.

Just FYI - this page still only mentions Python 2.7, presumably it needs updating: https://cloud.google.com/appengine/docs/standard/
Post reply on HN