Deleplace / programming-idioms

A collection of good snippets, in a lot of languages
Apache License 2.0
128 stars 8 forks source link

Backend multitenancy #86

Open Deleplace opened 5 years ago

Deleplace commented 5 years ago

See https://cloud.google.com/appengine/docs/standard/go/multitenancy/multitenancy

Any alternative "version" of the backend, even assigned 0% traffic, poses a risk of confusion of the Datastore data, the Memcache data, the Search indexes, and the delayed Tasks.

Make sure that alternative versions can never mess up with the prod data.

Deleplace commented 5 years ago

This may be taken care of in funcs handle and handleAjax, with (*Request).WithContext and appengine.Namespace

Deleplace commented 5 years ago

Not that easy: I end up with panic: appengine: NewContext passed an unknown http.Request

Deleplace commented 5 years ago

https://github.com/Deleplace/programming-idioms/commits/issues/86-namespaces