Connecting to AppEngine Datastore in Development via Cloud Datastore API
You're looking to use the GCE instance to interact with the AppEngine datastore via the Cloud Datastore API. Below is a response to your posed issue.
Currently, this functionality is not supported in the development environment due to the different storage implementation used by the Java development server for Cloud Datastore and the Python development server for App Engine. This issue is being tracked on GitHub.
Developing a Google Cloud Datastore application in Go is feasible, but the go client library may encounter bugs. Notably, the development server does not support the JSON API used by the go library.
Update:
An alternative suggestion from proppy involves utilizing the Cloud Datastore Protobuf HTTP API with Go.
Note that you can still use Cloud Datastore Protobuf HTTP API with Go. The protobuf definition is available on GitHub, you can compile it to Go code using the Go protobuf compiler plugin and then send POST HTTP requests to /datastore/{version}/datasets/{datasetId}/{method}.
This approach enables you to use the Cloud Datastore API through Protobuf requests. However, it requires manual HTTP request crafting and prevents data sharing between your application and the Cloud Datastore in development.
The above is the detailed content of How can I connect to AppEngine Datastore in development using the Cloud Datastore API with Go?. For more information, please follow other related articles on the PHP Chinese website!