Skip to content

Commit

Permalink
Reduce javadoc warnings (#4764)
Browse files Browse the repository at this point in the history
Summary:
Compile logs have a bit of noise due to missing javadoc annotations. Updating docs to reduce.
Pull Request resolved: #4764

Differential Revision: D13400193

Pulled By: sagar0

fbshipit-source-id: 65c7efb70747cc3bb35a336a6881ea6536ae5ff4
  • Loading branch information
adam-singer authored and facebook-github-bot committed Dec 10, 2018
1 parent 21fca39 commit 10e7de7
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@ public abstract T createCompactionFilter(
* A name which identifies this compaction filter
*
* The name will be printed to the LOG file on start up for diagnosis
*
* @return name which identifies this compaction filter.
*/
public abstract String name();

Expand Down
6 changes: 6 additions & 0 deletions java/src/main/java/org/rocksdb/ColumnFamilyOptions.java
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,9 @@ public ColumnFamilyOptions setMergeOperator(
* {@link #setCompactionFilter(AbstractCompactionFilter)} takes precedence
* over {@link #setCompactionFilterFactory(AbstractCompactionFilterFactory)}
* if the client specifies both.
*
* @param compactionFilter The compaction filter called during compaction.
* @return the reference to {@link org.rocksdb.ColumnFamilyOptions instance}.
*/
//TODO(AR) need to set a note on the concurrency of the compaction filter used from this method
public ColumnFamilyOptions setCompactionFilter(
Expand All @@ -218,6 +221,9 @@ public ColumnFamilyOptions setCompactionFilter(
* A new filter will be created on each compaction run. If multithreaded
* compaction is being used, each created CompactionFilter will only be used
* from a single thread and so does not need to be thread-safe.
*
* @param compactionFilterFactory The factory used for creating a new filter on each compaction run.
* @return the reference to {@link org.rocksdb.ColumnFamilyOptions instance}.
*/
public ColumnFamilyOptions setCompactionFilterFactory(final AbstractCompactionFilterFactory<? extends AbstractCompactionFilter<?>> compactionFilterFactory) {
assert (isOwningHandle());
Expand Down
1 change: 1 addition & 0 deletions java/src/main/java/org/rocksdb/DBOptionsInterface.java
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,7 @@ public interface DBOptionsInterface<T extends DBOptionsInterface> {
* first db_path (db_name if db_paths is empty).
*
* @param sstFileManager The SST File Manager for the db.
* @return the instance of the current object.
*/
T setSstFileManager(SstFileManager sstFileManager);

Expand Down
10 changes: 10 additions & 0 deletions java/src/main/java/org/rocksdb/SstFileManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ public final class SstFileManager extends RocksObject {
* instances to track SST file and control there deletion rate.
*
* @param env the environment.
*
* @throws RocksDBException thrown if error happens in underlying native library.
*/
public SstFileManager(final Env env) throws RocksDBException {
this(env, null);
Expand All @@ -39,6 +41,8 @@ public SstFileManager(final Env env) throws RocksDBException {
*
* @param env the environment.
* @param logger if not null, the logger will be used to log errors.
*
* @throws RocksDBException thrown if error happens in underlying native library.
*/
public SstFileManager(final Env env, /*@Nullable*/ final Logger logger)
throws RocksDBException {
Expand All @@ -57,6 +61,8 @@ public SstFileManager(final Env env, /*@Nullable*/ final Logger logger)
* this value is set to 1024 (1 Kb / sec) and we deleted a file of size
* 4 Kb in 1 second, we will wait for another 3 seconds before we delete
* other files, Set to 0 to disable deletion rate limiting.
*
* @throws RocksDBException thrown if error happens in underlying native library.
*/
public SstFileManager(final Env env, /*@Nullable*/ final Logger logger,
final long rateBytesPerSec) throws RocksDBException {
Expand All @@ -78,6 +84,8 @@ public SstFileManager(final Env env, /*@Nullable*/ final Logger logger,
* @param maxTrashDbRatio if the trash size constitutes for more than this
* fraction of the total DB size we will start deleting new files passed
* to DeleteScheduler immediately.
*
* @throws RocksDBException thrown if error happens in underlying native library.
*/
public SstFileManager(final Env env, /*@Nullable*/ final Logger logger,
final long rateBytesPerSec, final double maxTrashDbRatio)
Expand All @@ -104,6 +112,8 @@ public SstFileManager(final Env env, /*@Nullable*/ final Logger logger,
* @param bytesMaxDeleteChunk if a single file is larger than delete chunk,
* ftruncate the file by this size each time, rather than dropping the whole
* file. 0 means to always delete the whole file.
*
* @throws RocksDBException thrown if error happens in underlying native library.
*/
public SstFileManager(final Env env, /*@Nullable*/final Logger logger,
final long rateBytesPerSec, final double maxTrashDbRatio,
Expand Down
11 changes: 11 additions & 0 deletions java/src/main/java/org/rocksdb/WriteBatchInterface.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ public interface WriteBatchInterface {
*
* @param key the specified key to be inserted.
* @param value the value associated with the specified key.
* @throws RocksDBException thrown if error happens in underlying native library.
*/
void put(byte[] key, byte[] value) throws RocksDBException;

Expand All @@ -34,6 +35,7 @@ public interface WriteBatchInterface {
* instance
* @param key the specified key to be inserted.
* @param value the value associated with the specified key.
* @throws RocksDBException thrown if error happens in underlying native library.
*/
void put(ColumnFamilyHandle columnFamilyHandle,
byte[] key, byte[] value) throws RocksDBException;
Expand All @@ -45,6 +47,7 @@ void put(ColumnFamilyHandle columnFamilyHandle,
* @param key the specified key to be merged.
* @param value the value to be merged with the current value for
* the specified key.
* @throws RocksDBException thrown if error happens in underlying native library.
*/
void merge(byte[] key, byte[] value) throws RocksDBException;

Expand All @@ -56,6 +59,7 @@ void put(ColumnFamilyHandle columnFamilyHandle,
* @param key the specified key to be merged.
* @param value the value to be merged with the current value for
* the specified key.
* @throws RocksDBException thrown if error happens in underlying native library.
*/
void merge(ColumnFamilyHandle columnFamilyHandle,
byte[] key, byte[] value) throws RocksDBException;
Expand All @@ -66,6 +70,7 @@ void merge(ColumnFamilyHandle columnFamilyHandle,
* @param key Key to delete within database
*
* @deprecated Use {@link #delete(byte[])}
* @throws RocksDBException thrown if error happens in underlying native library.
*/
@Deprecated
void remove(byte[] key) throws RocksDBException;
Expand All @@ -77,6 +82,7 @@ void merge(ColumnFamilyHandle columnFamilyHandle,
* @param key Key to delete within database
*
* @deprecated Use {@link #delete(ColumnFamilyHandle, byte[])}
* @throws RocksDBException thrown if error happens in underlying native library.
*/
@Deprecated
void remove(ColumnFamilyHandle columnFamilyHandle, byte[] key)
Expand All @@ -86,6 +92,7 @@ void remove(ColumnFamilyHandle columnFamilyHandle, byte[] key)
* <p>If the database contains a mapping for "key", erase it. Else do nothing.</p>
*
* @param key Key to delete within database
* @throws RocksDBException thrown if error happens in underlying native library.
*/
void delete(byte[] key) throws RocksDBException;

Expand All @@ -94,6 +101,7 @@ void remove(ColumnFamilyHandle columnFamilyHandle, byte[] key)
*
* @param columnFamilyHandle {@link ColumnFamilyHandle} instance
* @param key Key to delete within database
* @throws RocksDBException thrown if error happens in underlying native library.
*/
void delete(ColumnFamilyHandle columnFamilyHandle, byte[] key)
throws RocksDBException;
Expand Down Expand Up @@ -161,6 +169,7 @@ void singleDelete(final ColumnFamilyHandle columnFamilyHandle,
* First key to delete within database (included)
* @param endKey
* Last key to delete within database (excluded)
* @throws RocksDBException thrown if error happens in underlying native library.
*/
void deleteRange(byte[] beginKey, byte[] endKey) throws RocksDBException;

Expand All @@ -178,6 +187,7 @@ void singleDelete(final ColumnFamilyHandle columnFamilyHandle,
* First key to delete within database (included)
* @param endKey
* Last key to delete within database (excluded)
* @throws RocksDBException thrown if error happens in underlying native library.
*/
void deleteRange(ColumnFamilyHandle columnFamilyHandle, byte[] beginKey,
byte[] endKey) throws RocksDBException;
Expand All @@ -195,6 +205,7 @@ void deleteRange(ColumnFamilyHandle columnFamilyHandle, byte[] beginKey,
* replication.
*
* @param blob binary object to be inserted
* @throws RocksDBException thrown if error happens in underlying native library.
*/
void putLogData(byte[] blob) throws RocksDBException;

Expand Down

0 comments on commit 10e7de7

Please sign in to comment.