impl/memory: datastore and memcache namespacing

Update GetNamespace() to return an additional boolean, which will be
true if the namespace was set and false if it was not. The AppEngine SDK
defaults to having no namespace installed ("", false), but will allow
the user to install any namespace. This allows a user to differentiate
between no namespace and an empty namespace ("", true).

Make impl/memory's datastore query operation to error if the namespace has
been set to the empty namespace (""). This reflects observed production
behavior.

BUG=

Review URL: https://codereview.chromium.org/1916463004
19 files changed
tree: 0becfb84fc23344e897212b972231d4a8fce5a70
  1. filter/
  2. impl/
  3. infra/
  4. service/
  5. tools/
  6. .travis.yml
  7. codereview.settings
  8. doc.go
  9. LICENSE
  10. pre-commit-go.yml
  11. PRESUBMIT.py
  12. README.md
  13. symbols.go
README.md

gae: A Google AppEngine SDK wrapper

designed for testing and extensibility

THIS PACKAGE HAS NO API COMPATIBILITY GUARANTEES. USE UNPINNED AT YOUR OWN PERIL.

(but generally it should be pretty stableish).

GoDoc Build Status Coverage Status

Installing

go get -u github.com/luci/gae/...

Why/What/How

See the godocs.

Versioning

  • Branch master contains the latest code.

Contributing

  • Sign the Google CLA.
  • Make sure your user.email and user.name are configured in git config.
  • Install the pcg git hook: go get -u github.com/maruel/pre-commit-go/cmd/... && pcg

Run the following to setup the code review tool and create your first review:

git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git $HOME/src/depot_tools
export PATH="$PATH:$HOME/src/depot_tools"
cd $GOROOT/github.com/luci/gae
git new-branch work
# or `git checkout -b work origin/master` if you like typing more.

# hack hack

git commit -a -m "This is awesome\nR=joe@example.com"
# This will ask for your Google Account credentials.
git cl upload -s
# Wait for LGTM over email.
# Check Commit Queue checkbox in Rietveld codereview site.
# See it tested and landed automatically.

Use git cl help and git cl help <cmd> for more details.