Skip to content

docstore/gcpdatastore: Add support for Google Firestore in Datastore mode #2713

@szabba

Description

@szabba

example.zip

Is your feature request related to a problem? Please describe.

The docstore API cannot be used with Google Cloud Firestore in Datastore mode.
The docstore/gcpfirestore driver is not sufficient for this -- trying to results in an error:

2019/12/11 19:51:32 could not save foo: docstore (code=FailedPrecondition): rpc error: code = FailedPrecondition desc = The Cloud Firestore API is not available for Datastore Mode projects.

See the attached example program.
It uses GCP application default credentials.
It expects a GCP project name in the GCP_PROJECT_NAME environment variable.

Describe the solution you'd like

A driver implementation for Google Cloud Firestore in Datastore mode.

Describe alternatives you've considered

Using a different backing service or cloud provider.

Additional context

The GCP Firestore documentation mentions Native Mode has a limit of 10k writes/s.
This makes it unsuitable for write-heavy workloads at certain scales.
While Docstore Mode does not have an exact figure for it's upper writes/s limit it indicates the limit isn't as low.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions