Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions 12 src/main/java/org/lmdbjava/Env.java
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
import java.util.List;

import jnr.ffi.Pointer;
import jnr.ffi.byref.IntByReference;
import jnr.ffi.byref.PointerByReference;
import org.lmdbjava.Library.MDB_envinfo;
import org.lmdbjava.Library.MDB_stat;
Expand Down Expand Up @@ -500,6 +501,15 @@ private void validatePath(final File path) {
validateDirectoryEmpty(path);
}


/* Check for stale entries in the reader lock table. */
public int readerCheck() {
final IntByReference resultPtr = new IntByReference();
checkRc(LIB.mdb_reader_check(ptr, resultPtr));
return resultPtr.intValue();
}


/**
* Object has already been closed and the operation is therefore prohibited.
*/
Expand Down Expand Up @@ -530,6 +540,7 @@ public AlreadyOpenException() {
}
}


/**
* Builder for configuring and opening Env.
*
Expand Down Expand Up @@ -595,6 +606,7 @@ public Env<T> open(final File path, final EnvFlags... flags) {
return open(path, 0664, flags);
}


/**
* Sets the map size.
*
Expand Down
2 changes: 1 addition & 1 deletion 2 src/main/java/org/lmdbjava/Library.java
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ int mdb_put(@In Pointer txn, @In Pointer dbi, @In Pointer key,
@In Pointer data,
int flags);

int mdb_reader_check(@In Pointer env, int dead);
int mdb_reader_check(@In Pointer env, @Out IntByReference dead);

int mdb_set_compare(@In Pointer txn, @In Pointer dbi, ComparatorCallback cb);

Expand Down
Morty Proxy This is a proxified and sanitized view of the page, visit original site.