Firebase's realtime database SDK has callback methods built in which allow the client to listen for database changes. (e.g. as per https://firebase.google.com/docs/database/android/start/)
Does Azure have any functionality like that in either the SQL Database or DocumentDB products? If not, why not? And what is the best way to achieve this functionality using Azure?
Thanks.
Edit context: I'm building a cross-platform mobile app using Xamarin.
"Realtime backend made easy", "Fast and responsive" and "Easy setup" are the key factors why developers consider Firebase; whereas "Scales well and quite easy", "Can use . Net or open source tools" and "Startup friendly" are the primary reasons why Microsoft Azure is favored.
Set the event handler Functions let you handle Realtime Database events at two levels of specificity; you can listen for specifically for only creation, update, or deletion events, or you can listen for any change of any kind to a path.
If you're looking for a full back-end as a service (BEaaS) and the least possible effort, Firebase is ideal, but MongoDB (and specifically MongoDB Atlas) gives you the most powerful and flexible platform for application development, and the ability to support both transactional and warehouse-style workloads in the same ...
Cloud Firestore is Firebase's newest database for mobile app development. It builds on the successes of the Realtime Database with a new, more intuitive data model. Cloud Firestore also features richer, faster queries and scales further than the Realtime Database. Realtime Database is Firebase's original database.
Microsoft just announced a new feature in DocDb called Change Feed which sounds like what you are looking for. It is enabled by default and included in the cost of DocDb.
From their announcement: "With Change Feed support, DocumentDB provides a sorted list of documents within a DocumentDB collection in the order in which they were modified. This feed can be used to listen for modifications to data within the collection and perform actions..."
Documentation on how to work with the change feed can be found here: https://docs.microsoft.com/en-us/azure/documentdb/documentdb-change-feed
Azure's SQL Database service now has Extended Events (currently in Preview). More info here.
DocumentDB does not have events you can subscribe to. You would need to build your own mechanism for taking action when modifying your database contents.
EDIT: Cosmos DB (formerly called DocumentDB, when this answer was originally posted) provides a change feed you can subscribe to.
As for "best way to achieve this functionality" - there is no best way. It's whatever you decide to build, based on your app, chosen frameworks, etc.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With