diff --git a/benchmark/bench_db.cpp b/benchmark/bench_db.cpp index 7fdfde80..51264883 100644 --- a/benchmark/bench_db.cpp +++ b/benchmark/bench_db.cpp @@ -10,6 +10,7 @@ #include "td/db/binlog/ConcurrentBinlog.h" #include "td/db/BinlogKeyValue.h" #include "td/db/SeqKeyValue.h" +#include "td/db/SqliteConnectionSafe.h" #include "td/db/SqliteDb.h" #include "td/db/SqliteKeyValueAsync.h" diff --git a/benchmark/bench_tddb.cpp b/benchmark/bench_tddb.cpp index 48c81e9c..d997c523 100644 --- a/benchmark/bench_tddb.cpp +++ b/benchmark/bench_tddb.cpp @@ -13,6 +13,8 @@ #include "td/actor/actor.h" #include "td/actor/PromiseFuture.h" +#include "td/db/SqliteConnectionSafe.h" + #include "td/utils/benchmark.h" #include "td/utils/buffer.h" #include "td/utils/common.h" @@ -77,7 +79,7 @@ class MessagesDbBench : public Benchmark { } private: - td::unique_ptr scheduler_; + td::unique_ptr scheduler_; std::shared_ptr sql_connection_; std::shared_ptr messages_db_sync_safe_; std::shared_ptr messages_db_async_; diff --git a/td/telegram/DialogDb.cpp b/td/telegram/DialogDb.cpp index c6890f87..18ebacc2 100644 --- a/td/telegram/DialogDb.cpp +++ b/td/telegram/DialogDb.cpp @@ -11,6 +11,7 @@ #include "td/actor/actor.h" #include "td/actor/SchedulerLocalStorage.h" +#include "td/db/SqliteConnectionSafe.h" #include "td/db/SqliteDb.h" #include "td/db/SqliteKeyValue.h" #include "td/db/SqliteStatement.h" diff --git a/td/telegram/DialogDb.h b/td/telegram/DialogDb.h index 6422a8a3..ede45031 100644 --- a/td/telegram/DialogDb.h +++ b/td/telegram/DialogDb.h @@ -12,8 +12,6 @@ #include "td/actor/PromiseFuture.h" -#include "td/db/SqliteConnectionSafe.h" - #include "td/utils/buffer.h" #include "td/utils/common.h" #include "td/utils/Status.h" @@ -22,6 +20,10 @@ #include namespace td { + +class SqliteConnectionSafe; +class SqliteDb; + class DialogDbSyncInterface { public: DialogDbSyncInterface() = default; @@ -87,4 +89,5 @@ std::shared_ptr create_dialog_db_sync( std::shared_ptr create_dialog_db_async(std::shared_ptr sync_db, int32 scheduler_id); + } // namespace td diff --git a/td/telegram/MessagesDb.cpp b/td/telegram/MessagesDb.cpp index 5b497380..f2acc5f6 100644 --- a/td/telegram/MessagesDb.cpp +++ b/td/telegram/MessagesDb.cpp @@ -9,6 +9,7 @@ #include "td/telegram/logevent/LogEvent.h" #include "td/telegram/Version.h" +#include "td/db/SqliteConnectionSafe.h" #include "td/db/SqliteDb.h" #include "td/db/SqliteStatement.h" diff --git a/td/telegram/MessagesDb.h b/td/telegram/MessagesDb.h index a7ecd15b..88c4592a 100644 --- a/td/telegram/MessagesDb.h +++ b/td/telegram/MessagesDb.h @@ -12,8 +12,6 @@ #include "td/actor/PromiseFuture.h" -#include "td/db/SqliteConnectionSafe.h" - #include "td/utils/buffer.h" #include "td/utils/common.h" #include "td/utils/logging.h" @@ -24,6 +22,9 @@ namespace td { +class SqliteConnectionSafe; +class SqliteDb; + // append only before Size enum class SearchMessagesFilter : int32 { Empty, diff --git a/td/telegram/TdDb.cpp b/td/telegram/TdDb.cpp index 60dec784..f61478d3 100644 --- a/td/telegram/TdDb.cpp +++ b/td/telegram/TdDb.cpp @@ -18,6 +18,7 @@ #include "td/db/binlog/Binlog.h" #include "td/db/binlog/ConcurrentBinlog.h" #include "td/db/BinlogKeyValue.h" +#include "td/db/SqliteConnectionSafe.h" #include "td/db/SqliteKeyValue.h" #include "td/db/SqliteKeyValueAsync.h" #include "td/db/SqliteKeyValueSafe.h" diff --git a/td/telegram/files/FileDb.cpp b/td/telegram/files/FileDb.cpp index 0bd9408a..a7d028df 100644 --- a/td/telegram/files/FileDb.cpp +++ b/td/telegram/files/FileDb.cpp @@ -11,6 +11,7 @@ #include "td/actor/actor.h" +#include "td/db/SqliteConnectionSafe.h" #include "td/db/SqliteKeyValue.h" #include "td/db/SqliteKeyValueSafe.h" diff --git a/test/db.cpp b/test/db.cpp index f91fa93f..37d4acf2 100644 --- a/test/db.cpp +++ b/test/db.cpp @@ -6,6 +6,7 @@ // #include "td/db/binlog/BinlogHelper.h" #include "td/db/binlog/ConcurrentBinlog.h" +#include "td/db/SqliteConnectionSafe.h" #include "td/db/BinlogKeyValue.h" #include "td/db/SeqKeyValue.h" #include "td/db/SqliteKeyValue.h"