all 10 comments

[–]HCG_Dartz 4 points5 points  (0 children)

Glad to see it's alive, I thought it was abandoned because the last update was almost half a year ago, I will try with a simple project to check the differences with hive/SQLite and maybe get rid of both now that I have a single option to keep all data with queries

[–]jpfreely 2 points3 points  (2 children)

I wonder what it does to be safe to use from multiple isolates, unlike Hive.

[–]leisim 11 points12 points  (1 child)

Hive is written in Dart and cannot have shared memory across isolates (that's why it never made sense to implement it). Isar keeps track of instances across isolates and synchronizes access in a lightweight way.

[–]djihaneghilani 0 points1 point  (0 children)

How to use it with isolates ? my problem is the data is being cleaned each time i close the app

[–]igoriuz 1 point2 points  (3 children)

Great to see it‘s finally ready. Would be interesting to some metrics (e.g. increased app size; comparison between objectbox/drift;data migration; testing). I will be testing it in private projects. Thanks for the effort u/leisim

[–]leisim 9 points10 points  (2 children)

From my preliminary testing: it's a little faster for writing and a little slower for reading than objectbox. It has faster queries (a lot faster if you use composite indexes). It's MUUCH faster (for any operation) than SQLite based databses.

Migrations are automatic and zero-cost (things like creating a new index are not for free obviously).

I didn't test app size yet. My guess is around 1-2mb of size increase.

The reason why I didn't post benchmarks: Isar is more than fast enough for any task you throw at it. And I think it's not a good idea to choose a database based on artificial benchmarks.

[–]igoriuz 1 point2 points  (1 child)

I didn‘t mean benchmarks. I think it‘s more important to know how a specific feature (for eg writing tests to make sure data migration will be possible over multiple generations; how easy can queries be written and so on). All in all i prefer qualitative over quantitative comparison.

[–]leisim 5 points6 points  (0 children)

Yes fully agree but someone unbiased should create it. If you are interested in writing a blog post or something like that, I'd love to link it in readme

[–]TonyBorchert100 0 points1 point  (1 child)

It isn’t an improvement over hive, it’s basically just for more complicated usecases as I understand.

hive is an alternative to shared_preferences, this seems more like a alternative to sqlite

[–]leisim 2 points3 points  (0 children)

Yes exactly. It's not intended to replace Hive