Skip to content

Commit

Permalink
options: Forward declare WriteBufferManager (#279)
Browse files Browse the repository at this point in the history
There is a circular dependency between options.h and write_buffer_manager.h.
In order to fix that, I forward declare the WriteBufferManager class in
options.h and include it in options.cc and in other .cc files which
use WriteBufferManager.
  • Loading branch information
AmnonHanuhov authored and Yuval-Ariel committed May 2, 2023
1 parent ade5c48 commit 8772bfc
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion include/rocksdb/options.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
#include "rocksdb/types.h"
#include "rocksdb/universal_compaction.h"
#include "rocksdb/version.h"
#include "rocksdb/write_buffer_manager.h"

#ifdef max
#undef max
Expand All @@ -55,6 +54,7 @@ class Slice;
class Statistics;
class InternalKeyComparator;
class WalFilter;
class WriteBufferManager;
class FileSystem;
class WriteController;

Expand Down
1 change: 1 addition & 0 deletions options/db_options.cc
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
#include "rocksdb/system_clock.h"
#include "rocksdb/utilities/options_type.h"
#include "rocksdb/wal_filter.h"
#include "rocksdb/write_buffer_manager.h"
#include "util/string_util.h"

namespace ROCKSDB_NAMESPACE {
Expand Down
1 change: 1 addition & 0 deletions options/options.cc
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
#include "rocksdb/table.h"
#include "rocksdb/table_properties.h"
#include "rocksdb/wal_filter.h"
#include "rocksdb/write_buffer_manager.h"
#include "table/block_based/block_based_table_factory.h"
#include "util/compression.h"

Expand Down

0 comments on commit 8772bfc

Please sign in to comment.