rocksdb/java/rocksjni
Ramkumar Vadivelu 9a690a74e1 In ParseInternalKey(), include corrupt key info in Status (#7515)
Summary:
Fixes Issue https://github.com/facebook/rocksdb/issues/7497

When allow_data_in_errors db_options is set, log error key details in `ParseInternalKey()`

Have fixed most of the calls. Have few TODOs still pending - because have to make more deeper changes to pass in the allow_data_in_errors flag. Will do those in a separate PR later.

Tests:
- make check
- some of the existing tests that exercise the "internal key too small" condition are: dbformat_test, cuckoo_table_builder_test
- some of the existing tests that exercise the corrupted key path are: corruption_test, merge_helper_test, compaction_iterator_test

Example of new status returns:
- Key too small - `Corrupted Key: Internal Key too small. Size=5`
- Corrupt key with allow_data_in_errors option set to false: `Corrupted Key: '<redacted>' seq:3, type:3`
- Corrupt key with allow_data_in_errors option set to true: `Corrupted Key: '61' seq:3, type:3`

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

Reviewed By: ajkr

Differential Revision: D24240264

Pulled By: ramvadiv

fbshipit-source-id: bc48f5d4475ac19d7713e16df37505b31aac42e7
2020-10-28 10:12:58 -07:00
..
backupablejni.cc
backupenginejni.cc
cassandra_compactionfilterjni.cc
cassandra_value_operator.cc
checkpoint.cc
clock_cache.cc
columnfamilyhandle.cc
compact_range_options.cc
compaction_filter.cc
compaction_filter_factory.cc
compaction_filter_factory_jnicallback.cc
compaction_filter_factory_jnicallback.h
compaction_job_info.cc
compaction_job_stats.cc
compaction_options.cc
compaction_options_fifo.cc
compaction_options_universal.cc
comparator.cc
comparatorjnicallback.cc
comparatorjnicallback.h
compression_options.cc
concurrent_task_limiter.cc
config_options.cc
env.cc
env_options.cc
event_listener.cc
event_listener_jnicallback.cc
event_listener_jnicallback.h
filter.cc
ingest_external_file_options.cc
iterator.cc
jnicallback.cc
jnicallback.h
loggerjnicallback.cc
loggerjnicallback.h
lru_cache.cc
memory_util.cc
memtablejni.cc
merge_operator.cc
native_comparator_wrapper_test.cc
optimistic_transaction_db.cc
optimistic_transaction_options.cc
options.cc
options_util.cc
persistent_cache.cc
portal.h
ratelimiterjni.cc
remove_emptyvalue_compactionfilterjni.cc
restorejni.cc
rocks_callback_object.cc
rocksdb_exception_test.cc
rocksjni.cc
slice.cc
snapshot.cc
sst_file_manager.cc
sst_file_reader_iterator.cc
sst_file_readerjni.cc
sst_file_writerjni.cc
sst_partitioner.cc
statistics.cc
statisticsjni.cc
statisticsjni.h
table.cc
table_filter.cc
table_filter_jnicallback.cc
table_filter_jnicallback.h
testable_event_listener.cc
thread_status.cc
trace_writer.cc
trace_writer_jnicallback.cc
trace_writer_jnicallback.h
transaction.cc
transaction_db.cc
transaction_db_options.cc
transaction_log.cc
transaction_notifier.cc
transaction_notifier_jnicallback.cc
transaction_notifier_jnicallback.h
transaction_options.cc
ttl.cc
wal_filter.cc
wal_filter_jnicallback.cc
wal_filter_jnicallback.h
write_batch.cc
write_batch_test.cc
write_batch_with_index.cc
write_buffer_manager.cc
writebatchhandlerjnicallback.cc
writebatchhandlerjnicallback.h