Reputation: 9255
I am trying to track user events in my android app by storing in a database in the backend. I am using Google App Engine for my mobile backend. I am trying to figure out whether Datastore in Google App Engine is suited for this. Also, I came across Bigtable (Billed functionality) for NoSQL.
What are the pros and cons of using Cloud Datastore vs Bigtable in Google App Engine?
Also, I couldn't find a way to automatically purge old data (i.e., older than a specific day etc.) in Datastore (I found some suggestions to use a cron-job).
Upvotes: 2
Views: 695
Reputation: 2711
Cloud Bigtable doesn't currently work on Google App Engine standard, but that feature is actively being worked on. Cloud Bigtable does current Google App Engine flexible.
To get user events into Bigtable, you'd have to use a slightly different architecture. Here's a talk about IoT which is similar to capturing user events in that it's time series data that doesn't change: https://www.youtube.com/watch?v=8PibIlXmd-Q
Cloud Bigtable is good for cases where you want to optimize throughput for a large load. The smallest Cloud Bigtable setup allows for 30k QPS (queries per second). The cost relates to how much throughput you need, which translates to the node count, and how much storage you use.
All of this said, Cloud Datastore should be more straightforward to use. Cloud Bigtable is a more specialized tool and requires a level of expertise in schema design and table management.
Cloud Bigtable purges do happen automatically if you set the timestamp correctly.
You can see more in the Overview of Cloud Bigtable.
NOTE: This post was Edited 6/18 in the evening.
Upvotes: 2
Reputation: 3443
Have you considered Google Analytics? https://developers.google.com/analytics/devguides/collection/android/v4/#set-up-your-project
Upvotes: 0