Is it possible to enable multi-region write for Azure Cosmos DB only for a subset of regions? So have 5 read regions but only 3 of those as write regions for example? I'd assume this would save costs but can't find that this is possible. When I enable multi-region write it just makes a read and write region of every region I add.
This is not possible. Enabling multi-region writes makes every region writable in Cosmos DB.
Related
So I have set the location of my Firestore database to asia-south-1, let suppose now I start getting users from the US as well as from India, how will I serve both the groups with lower latency?
You can't change the properties of your project once it's set up, nor even simply pay more for better service. If you want improved service in different regions, you will need to buy computing resources in each of those regions. This requires setting up multiple projects, with each Firestore product configured for the region you want improved service. Note that not all Firebase and GCP products are available in all regions.
If you want all users in all regions to be using the same set of data with improved latency, that's not possible to configure. You will have to build a way to mirror data between the different projects. There is nothing terribly easy about that, nor are there any existing solutions offered by Firebase or GCP to do this for you.
Doug nailed it for Firestore. So 👍
Note that Firebase's Realtime Database (unlike Firestore) can have multiple databases per project, which means you can set up a database instances in each region (it support three right now) and redirect your user's traffic to the region closest to them. You may still have to replicate data between the database instances, similar to Doug's answer, but (unlike in Doug's answer) with Realtime Database this can happen within a single project.
I want to use Datastore (Firestore in Datastore mode) in europe-west1. Since Datastore is not available as a regional location in europe-west1 I will go with the multi-region location (which consists of europe-west1 and europe-west4 according to this doc).
Do I understand data replication correctly in that if I store data in Datastore, Google automatically stores all the data in both regions europe-west1, europe-west4?
Can I disable data replication in europe-west4 since I just want to use Datastore in europe-west1?
Also just for my understanding: If multi-regional means there is a Data Center in each region why are both not available as single regional location?
Any help is appreciated.
The multi-region in GCP makes all the data replication automatically and this is by design, so that you have higher availability, performance, and resource efficiency and this is out of your control, so you can't disable data replication in a multi-region environment.
To your second question there is nothing that justifies this in the documentation, so I assume unofficially that this happens because Google simply does not allow for individual regions for that particular reason because it's not the focus of that particular region and acts just as a replicated location for that particular product when set to multi-region.
I want to see the partitions where there is a lot of reads and writes
I also want to see the partitions where there's been no crud operations for long, so that I can clean it up
is that possible in cosmos db ?
Question: I want to know what are the partitions which are hot or inactive,
having to read or write on it
According to your further description,you want to know the distribute situations of requests cross your multiple partitions.
Actually,that metric could be touched in the Azure Portal Metrics Throughput tab.
You could determine the throughput distribution of any partitioned container broken down by partitions.More details,please refer to this document.
I know scalability is not an issue in Firebase and supports up to 100k Simultaneous connections(in general).
Based on pricing documentation:
You can create multiple database instances to go beyond the 100K
concurrent limit. See Pricing FAQ for more information.
Question 1: What if there is more than 200k users using simultaneously on the same database? The other half of the users could not query, connect or the request will be placed in queue?
(As a Firebase plan subscriber, I would like to know how Firebase deals with the problem to ensure the quality of the services provided to our customers are always in top-notch)
Since, App globalisation is common nowadays and many companies' practices are to have servers across multiple regions to provide better and stable performance. Online game for example which required low latency.
As for now, the firebase user is required to set the default location when creating the project which is non-editable afterward. Some issues even rises where the users realised they deployed their app to the wrong regions and do not have clues on how to change the regions.
This represents the country/region of your organisation/company. Your
selection also sets the appropriate currency for your revenue
reporting. The selected country does not determine the location of
your data for Firebase features. Google may process and store Customer
Data anywhere Google or its agents maintain facilities.
Question 2: Will or does Firebase provide a solution / tailor-made to such practice which having our database in multiple regions while having a headquartered region and multiple other regions sharing all the databases, functions and auth across the regions?
(For now to have multiple servers location, we have to create different projects and the user and data syncing will be a problem)
Hope the language does not offend, cheers!
It seems like your question (or at least your assumptions) is based on the Firebase Realtime Database, so I'll answer for that below.
Q1) You can create more than 2 databases in a single project, each of which allows 100K connections. So it can scale beyond 200K connections. All of these are hosted in the same region though, so you can't use each database for a separate region.
Q2) For a database solution that handles multiple regions, I'd recommend looking at Cloud Firestore. Also see: Cloud Firestore - selecting region to store data?
I'm working on a product which for legal reasons needs to store user data in a specific region.
I'm using Firebase so I created a project selecting the region it needs to be in however looking at firestore where the user data is kept I can't find anything pinpointing the region the data actually is. The thing which makes me worry the most is the Cloud Functions endpoints start with us-central1 but obviously that could just be that cloud functions don't exist in the specified region.
Given this is an important matter is there a way to confirm the location of data and even force it to be in a specific region?
Update
Cloud Firestore supports the following regional GCP resource locations, in addition to the 2 multi-region (nam5, eur3) locations:
See the documentation for an up-to-date list of locations.
Original Answer
Cloud Firestore is currently only available in our US multi-region (Iowa, Oklahoma, South Carolina). As we approach GA we plan to roll it out to multiple locations across the globe and you'll be able to select which one at creation time. Not something you can do today though.