Questions tagged [objectbox-java]

For questions about the Java API for ObjectBox. ObjectBox is an object-oriented embedded database. Refer to tag "objectbox" for more details regarding ObjectBox.

10 questions
2
votes
1 answer

100k inserts in Realm is slow, taking 30 seconds. Shall I use ObjectBox?

I have used Realm DB in my app for the last two years. Up to now, it is working fine. Now for an upgrade to my app during app startup, I need to insert close to 100k entries to Realm DB from JSON. In this case, it took 30 seconds to insert. I cant…
Bala Pravin
  • 101
  • 5
2
votes
1 answer

ObjectBox, how to drop-everything migration on conflicts?

In my case saved data can be cleaned without fear in case of model changes, there is a better way to do this ? private val dataSource = try { MyObjectBox.builder().androidContext(context).build().boxFor(XXXX::class) } catch (e: Exception) { …
Alessandro Scarozza
  • 4,273
  • 6
  • 31
  • 39
1
vote
0 answers

How to connect ObjectBox to server instance?

I have a use-case wherein I have to connect objectbox from Java to server instance. I tried with Sync but getting error stating "sync not supported". Below is my code, BoxStore boxStore =…
1
vote
1 answer

Does ObjectBox Swift allow conflict strategies for unique entity annotations?

ObjectBox's Java api has a unique entity annotation which allows you to specify a conflict strategy @Unique(onConflict = ConflictStrategy.REPLACE) Does the Swift api provide similar options for its unique annotation?
pdiffley
  • 603
  • 9
  • 18
0
votes
1 answer

Can I share an ObjectBox database (mdb files) between two Java applications

So I currently have a server running for an online game, and one of the ObjectBox boxes is for users, which holds things like email address, name etc. I am just starting on a second game, and I want my users to be able to use the same set of info to…
Russ Wheeler
  • 2,590
  • 5
  • 30
  • 57
0
votes
0 answers

java moulde.info desktop objectbox

I am having an issue setting up the module.info file for my java desktop app, I am using object box desktop as a database, so I am stuck at this error, I am using maven. java: the unnamed module reads package io.objectbox.converter from both…
kinsley kajiva
  • 1,840
  • 1
  • 21
  • 26
0
votes
1 answer

Objectio dB database for Java desktop persistance

I have been trying out object ox io for Java. It has been working well on Android hence I decided to go with it on Java desktop implementation. The problem I am facing is that I can save my data at run time but when I restart the app or desktop app…
kinsley kajiva
  • 1,840
  • 1
  • 21
  • 26
0
votes
1 answer

Can the *.mdb file be open in two thread at the same time?

Android Objectbox Version 3.1.2 Flutter Objectbox Version 1.4.1 Android code does read/write operation Flutter code only does read operation Sometimes the android side throws this exception: Could not renew tx (another read transaction is still…
0
votes
1 answer

ObjectBox: problem opening in Dart a DB file created in Java

I had a running app in Java on Android, and now I try to migrate it to Flutter/Dart. So I re-created the models in Dart and tried the best to match the types with Java. One thing I noticed that can't be exactly matched is model inheritance in Java…
LXJ
  • 1,180
  • 6
  • 18
0
votes
3 answers

ObjectBox does not keep previous values after type migration

We had to migrate one of the field-params in an entity from long to BigDecimal. Migration is quite smooth but there is a problem; we want to keep previous values to be set to the migrated field. But as soon as ObjectBox is initialized it defaults…