Storage metadata in Google Cloud Datastore

Google Datastore is a highly scalable, NoSQL document database similar to Amazon's DynamoDB and MongoDB. Individual data objects in the Datastore are called entities. An entity has one or more properties and a category of objects is called a kind. Each object is uniquely identified by a key. In this recipe, we would simulate a storage drive environment. Employees of a company are given the ability to upload files to Google Storage. The metadata is stored in Cloud Datastore to avoid overhead to the Storage API and for efficiency. The file uploaded to the Storage follows this file format:

<5-digit hash>/<[year][month][day][hour][minute][second]>/<Employee ID>/<file name>

After the data is uploaded ...

Get Google Cloud Platform Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.