You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
String name = "user";
User admin = new User().setUserName("admin");
Atomic.Var<Object> var = db.atomicVar(name).createOrOpen();
User user = (User) var.get();
// user should be null
Assertions.assertNull(user);
// set AtomicVar
var.set(admin);
user = (User) var.get();
Assertions.assertEquals(admin, user);
// rollback and get will throw exception
db.rollback();
user = (User) var.get();
It throw an exception in line user = (User) var.get(); after rollback
org.mapdb.DBException$GetVoid: Record does not exist, recid=10
at org.mapdb.StoreWAL.getIndexVal(StoreWAL.kt:170)
at org.mapdb.StoreWAL.get(StoreWAL.kt:500)
at org.mapdb.Atomic$Var.get(Atomic.java:751)
at com.mapdbtest.DBServiceTest.testRollback(DBServiceTest.java:110)
The text was updated successfully, but these errors were encountered:
Montaro2017
changed the title
After rollback will throw exception
Retrieving data after rollback will throw an exception
Nov 23, 2023
versioin
code
It throw an exception in line
user = (User) var.get();
after rollbackThe text was updated successfully, but these errors were encountered: