Which datastore method should I be using?

Today, I have been wondering about how I should set up my datastore, but the problem is that I don’t know what save method I should use. I have been thinking about using berezaa method where you save a key number or os.time() and compare it to the highest number, which is using GetOrderedDataStore or I should use normal datastores that uses GetAsync, UpdateAsync, and SetAsync.

Which is method is better to use and prevented data loss.

First of all. All events and functions run the same, so no more or less will prevent data loss.

In my perspective, there are 3 ways to store data.

  1. Basic normal GetDataStore

  2. GetOrderedDataStore

  3. Do what most large game developers do and run an external datstore

The first two, like I said, run no different than each other.

The third really depends on the company

1 Like

GlobalDataStores and OrderedDataStores are different though. Certain request types adhere to different per-minute budgets and their use cases also differ. The former is used for storing all kinds of serialisable data while the latter is only for 64-bit integers and intended for ordered saving.

Roblox DataStores are sufficient enough for almost all data saving use cases, especially now that they support more storage in them. You should typically stay away from external databases unless you absolutely need tooling and integration that can’t be provided by using Roblox DataStores and said integrations are critical for your game’s experience.

When it comes to avoiding data loss, it’s all about working around the budget: getting the most out of a few requests per player. Frankly you can get away with any kind of setup and you’ll be fine, you don’t need the backups method (that’ll be natively supported in the future anyway). It’s important to battle test these solutions after developing them.

1 Like

if you want to prevent data loss, i think you should check out data store 2

Nah, use ProfileService instead, way better.