N5 library implementation using Google Cloud Storage backend.
- N5 containers are represented by buckets.
- An
attributes.json
with an empty map is always created for any group. It is used to reliably check group existence as Google Cloud Storage does not have conventional directories. - In Google Cloud Storage, buckets are created within user projects. Thus, you will need to choose one of your projects in order to create a bucket. For reading a bucket, project id is not required as all buckets have unique names.
This test uses OAuth 2.0 authentication to run unit tests using actual Google Cloud Storage backend. It is excluded from the test run configuration by default and requires a few steps to set up:
- Create a project in the Google Cloud console.
- Enable Storage API and Resource Manager API.
- Go to APIs & services and choose Create credentials → OAuth client ID → Other.
- Run the test. You will be prompted for client_id and client_secret that are provided on the web page. They are needed to facilitate OAuth 2.0 in order to obtain user credentials. After that, both credentials and client secrets will be stored under
$user.home/.google/n5-google-cloud
and will be automatically loaded from there on all subsequent runs.