Fix Java build (#10105)

Summary: Pull Request resolved: https://github.com/facebook/rocksdb/pull/10105

Reviewed By: cbi42

Differential Revision: D36891073

Pulled By: ltamasi

fbshipit-source-id: 16487ec708fc96add2a1ebc2d98f6439dfc852ca
main
Levi Tamasi 3 years ago committed by Facebook GitHub Bot
parent b8fe7df2e5
commit 7b2c0140ba
  1. 29
      java/rocksjni/options.cc
  2. 2
      java/src/main/java/org/rocksdb/AdvancedMutableColumnFamilyOptionsInterface.java
  3. 2
      java/src/main/java/org/rocksdb/ColumnFamilyOptions.java
  4. 2
      java/src/test/java/org/rocksdb/BlobOptionsTest.java

@ -3843,7 +3843,7 @@ jlong Java_org_rocksdb_Options_blobCompactionReadaheadSize(JNIEnv*, jobject,
/*
* Class: org_rocksdb_Options
* Method: setBlobFileStartingLevel
* Signature: (JJ)V
* Signature: (JI)V
*/
void Java_org_rocksdb_Options_setBlobFileStartingLevel(
JNIEnv*, jobject, jlong jhandle, jint jblob_file_starting_level) {
@ -3854,7 +3854,7 @@ void Java_org_rocksdb_Options_setBlobFileStartingLevel(
/*
* Class: org_rocksdb_Options
* Method: blobFileStartingLevel
* Signature: (J)J
* Signature: (J)I
*/
jint Java_org_rocksdb_Options_blobFileStartingLevel(JNIEnv*, jobject,
jlong jhandle) {
@ -5646,6 +5646,31 @@ jlong Java_org_rocksdb_ColumnFamilyOptions_blobCompactionReadaheadSize(
return static_cast<jlong>(opts->blob_compaction_readahead_size);
}
/*
* Class: org_rocksdb_ColumnFamilyOptions
* Method: setBlobFileStartingLevel
* Signature: (JI)V
*/
void Java_org_rocksdb_ColumnFamilyOptions_setBlobFileStartingLevel(
JNIEnv*, jobject, jlong jhandle, jint jblob_file_starting_level) {
auto* opts =
reinterpret_cast<ROCKSDB_NAMESPACE::ColumnFamilyOptions*>(jhandle);
opts->blob_file_starting_level = jblob_file_starting_level;
}
/*
* Class: org_rocksdb_ColumnFamilyOptions
* Method: blobFileStartingLevel
* Signature: (J)I
*/
jint Java_org_rocksdb_ColumnFamilyOptions_blobFileStartingLevel(JNIEnv*,
jobject,
jlong jhandle) {
auto* opts =
reinterpret_cast<ROCKSDB_NAMESPACE::ColumnFamilyOptions*>(jhandle);
return static_cast<jint>(opts->blob_file_starting_level);
}
/////////////////////////////////////////////////////////////////////
// ROCKSDB_NAMESPACE::DBOptions

@ -762,7 +762,7 @@ public interface AdvancedMutableColumnFamilyOptionsInterface<
* Dynamically changeable through
* {@link RocksDB#setOptions(ColumnFamilyHandle, MutableColumnFamilyOptions)}.
*
* @param setBlobFileStartingLevel the starting level to enable blob files
* @param blobFileStartingLevel the starting level to enable blob files
*
* @return the reference to the current options.
*/

@ -1246,7 +1246,7 @@ public class ColumnFamilyOptions extends RocksObject
* Dynamically changeable through
* {@link RocksDB#setOptions(ColumnFamilyHandle, MutableColumnFamilyOptions)}.
*
* @param setBlobFileStartingLevel the starting level to enable blob files
* @param blobFileStartingLevel the starting level to enable blob files
*
* @return the reference to the current options.
*/

@ -196,7 +196,7 @@ public class BlobOptionsTest {
"blob_compaction_readahead_size", "blob_file_starting_level"});
assertThat(options.getValues())
.isEqualTo(new String[] {
"false", "4096", "2048", "LZ4_COMPRESSION", "false", "0.91", "0.96", "1024"});
"false", "4096", "2048", "LZ4_COMPRESSION", "false", "0.91", "0.96", "1024", "0"});
}
/**

Loading…
Cancel
Save