Accessing Datastore from Standard and Flexible services in local environment

72 views
Skip to first unread message

Nav Patel

unread,
Nov 21, 2016, 12:20:07 PM11/21/16
to Google App Engine
I had posted this previously, and was redirected here!

In summary: is there support for both a Standard and a Flexible services running alongside each other in the local dev environment? 

The specific issue I'm having:
1) "default" service in Standard environment: creates tasks
2) "processdata" service in Flexible-environment, picks up the task and processes data, it needs to write back into the Datastore

This seems like a pretty sensible setup; but I can't get my Standard service to use Datastore Emulator. And I can't get the Flexible-environment datastore to access the Datastore started by dev_appserver.py

It looks like there might be a solution here, but I can't get this to work. 

George (Cloud Platform Support)

unread,
Nov 21, 2016, 3:53:10 PM11/21/16
to Google App Engine

Hello Nav,


Local testing of your flex application uses Docker containers and actual Cloud Platform services, such as Google Cloud Datastore. By contrast, your app engine standard application is sandboxed in your local environment and uses a Datastore Emulator. In local testing, your flex and your standard applications do not access the same data store, so your scenario would stumble at this point.


More detail in this page on the migration of services from the Standard Environment to the Flexible Environment.


On the other hand, once deployed, you can use both environments in your application at the same time if you structure your application using the microservices architecture.

Jon Wayne Parrott

unread,
Nov 22, 2016, 2:00:26 PM11/22/16
to Google App Engine
Slight correction: local dev/test of flexible applications does not use docker. Though you can run your app in docker locally if you want.

Currently there isn't a way to point dev_appserver at the Cloud Datastore emulator, but we are aware of that this is a problem.
Reply all
Reply to author
Forward
0 new messages