DataKeep - A promise based, auto-saving DataStore module

About

DataKeep is a promise-based DataStore library that heavily mocks ProfileServices’ API for my convenience of switching.

Installation

See installation here.

I need help / I have a bug

Ping in the DataKeep thread on the Roblox OSS discord or, open an issue on the GitHub repository

Why DataKeep?

  • Easy to start & API is similar naming to ProfileService super easy to transfer over
  • Promise-based API to know exactly when things are done
  • Actively maintained codebase and easy to contribute, and to add future functionality
  • No getter/setter functions allowing for the developer to customize their experience
  • Session Locking
  • Spreads save calls equally out

ProfileService VS DataKeep

The original intent of this module was to fix issues I had with ProfileService (still a wonderful resource I recommend checking out if this is not for you)

ProfileService issues DataKeep aims to solve

  • Profiles do not automatically clean up internal connections, making the developer have to perform inconvenient clean-ups
  • ProfileService async calls make waiting for Profiles to be loaded difficult. Causing weird patterns when waiting for Profiles; DataKeep is promise-based
  • Shorter, scripts for faster future development, and contributors (vs ProfileService fitting classes inside one script for micro-performance)
  • Type checking, to a certain extent. There is a caveat due to Luau limitations, can not type check Promises (but it shows on documentation)
47 Likes

This appears to be good, but before I give it a try, I’ll wait to see what other people have to say and read reviews first.

5 Likes

I’ve went through the docs, and oh boy…

This is quite an interesting one!


Being honest, I started using ProfileService as DataStore2 went out of date and it didn’t have the session-locking feature, but for the past few days just using it is a little bit of a hassle.

Let’s say you’re making a game and you’re following the normal docs. It’ll first tell you to grab the code (literally huge, sometimes pasting in the code also causes lag). Again, when you’re using it you’d have to connect it with ReplicaService which is another problem I see. Of course, I’d have to do the same thing here, but working with DataKeep seems easier. The only reason I’m thinking of using this module is because of it using promises. Literally, if you want to keep your game secured, who wouldn’t?

Of course, no hate to ProfileService, but my personal opinion? I’m already in love with this. Another thing beside promises is its automation. It does many things internally which wasn’t a main feature in ProfileService.

Will probably try it out. Amazing job on doing something like this! I’d also like to hear other people’s opinions :sunglasses:

5 Likes

gonna test this out and see if i like this more than profileservice :slight_smile:

will edit post when done

1 Like

Awesome, have fun with it. If you need any help, reach out to the link provided above.

3 Likes


I don’t really know how to benchmark how good DataKeep is compared to ProfileService, so I’ll wait for reviews. If the reviews end up being positive, and people prefer this to ProfileService (which is a pain to use), I might switch!

Edit: Nvm, I’m trying it rn. The datastore scripts of my game are already broken, why not just redo the whole thing?

2 Likes

Really you can’t “benchmark” a data library, besides, speed isn’t really needed due to Roblox saving limits

ProfileService is great, this solution just introduces promises. If you aren’t interested in promises, use ProfileService

5 Likes

Fair. I mainly meant the ease of use and functionality, not speed, but I worded it poorly. The post by Arid sums up what excites me about this module.

1 Like

Version 1.1.5 release

A new patch was released that makes session locking a lot more stable as well as introduces:

Keep.MetaData.LoadCount & from the previous patch, Keep.MetaData.Created

2 Likes

Version 1.1.7

Implemented

  • CriticalState

  • IssueSignal

Improved

  • Promise caching + Keep caching

  • Some API documentation

  • Saving loop on shutdown

(version skip, just a bad build)

1 Like

Version 1.1.9

Fixed

  • Critical StoreInfo oversight
1 Like

What specifically does profileservice not clean up?

Hey! Sorry for the delay. Just noticed I wrote them complete on my checklist but actually forgot lol. But now done and will be published in the new patch coming.

But .OnRelease, and .OnGlobalUpdates automatically will clear connections. And any future signals. ProfileService does not for most, to my understanding and requires the developer to do so.

Which makes since in some designs the developer should control and always know the state of things, doesn’t hurt to wrap it into a cleaner if you want.

1 Like

version 1.2.0: 11/07/2023

Added

  • WriteLib functionality
  • Default WriteLib

Fixed

  • OnRelease fire bug

Improved

  • Cleanups

We really need tutorial for this, for people like me

I made it function but… I couldn’t do WriteLib for some reason

1 Like

version 1.2.1: 11/16/2023

Fixed

  • Data not saving
  • Basic Usage example

Improved

  • Reverted to an older method that works better for splitting up workload
1 Like


I think you forgot to place DataKeep-v1.2.1.rbxm

Thanks, the upload errored. Uploaded it now:)

1 Like

We definetly need Video Tutorial for this :d
I tried it do it but seems like i am doing something wrong.

I didn’t even get this confused when Using ProfileService man

A video would only cover basic usage. Currently, basic usage is provided and can see how it interacts with the API. Maybe in the future from community videos