diff --git a/silkworm/silkrpc/commands/debug_api_test.cpp b/silkworm/silkrpc/commands/debug_api_test.cpp index 67362aae65..3bb67cec68 100644 --- a/silkworm/silkrpc/commands/debug_api_test.cpp +++ b/silkworm/silkrpc/commands/debug_api_test.cpp @@ -180,10 +180,6 @@ class DummyTransaction : public ethdb::Transaction { co_return cursor; } - awaitable> create_state(const core::rawdb::DatabaseReader& /* db_reader */, uint64_t /* block_number */) override { - co_return nullptr; - } - std::shared_ptr create_state(boost::asio::any_io_executor&, const core::rawdb::DatabaseReader&, uint64_t) override { return nullptr; } diff --git a/silkworm/silkrpc/commands/engine_api_test.cpp b/silkworm/silkrpc/commands/engine_api_test.cpp index 2090ffb1b5..20a9c72203 100644 --- a/silkworm/silkrpc/commands/engine_api_test.cpp +++ b/silkworm/silkrpc/commands/engine_api_test.cpp @@ -74,10 +74,6 @@ namespace { co_return nullptr; } - awaitable> create_state(const core::rawdb::DatabaseReader& /* db_reader */, uint64_t /* block_number */) override { - co_return nullptr; - } - std::shared_ptr create_state(boost::asio::any_io_executor&, const core::rawdb::DatabaseReader&, uint64_t) override { return nullptr; } diff --git a/silkworm/silkrpc/core/account_dumper_test.cpp b/silkworm/silkrpc/core/account_dumper_test.cpp index c13fa1f4a9..0e2917d463 100644 --- a/silkworm/silkrpc/core/account_dumper_test.cpp +++ b/silkworm/silkrpc/core/account_dumper_test.cpp @@ -171,11 +171,6 @@ class DummyTransaction : public ethdb::Transaction { co_return cursor; } - boost::asio::awaitable> create_state(const core::rawdb::DatabaseReader& /* db_reader */, - uint64_t /* block_number */) override { - co_return nullptr; - } - std::shared_ptr create_state(boost::asio::any_io_executor&, const core::rawdb::DatabaseReader&, uint64_t) override { return nullptr; } diff --git a/silkworm/silkrpc/core/account_walker_test.cpp b/silkworm/silkrpc/core/account_walker_test.cpp index 047d46dd07..c31bfdc9ae 100644 --- a/silkworm/silkrpc/core/account_walker_test.cpp +++ b/silkworm/silkrpc/core/account_walker_test.cpp @@ -169,11 +169,6 @@ class DummyTransaction : public ethdb::Transaction { co_return cursor; } - boost::asio::awaitable> create_state(const core::rawdb::DatabaseReader& /* db_reader */, - uint64_t /* block_number */) override { - co_return nullptr; - } - std::shared_ptr create_state(boost::asio::any_io_executor&, const core::rawdb::DatabaseReader&, uint64_t) override { return nullptr; } diff --git a/silkworm/silkrpc/core/storage_walker_test.cpp b/silkworm/silkrpc/core/storage_walker_test.cpp index 8301911b1b..daf5b4e3fc 100644 --- a/silkworm/silkrpc/core/storage_walker_test.cpp +++ b/silkworm/silkrpc/core/storage_walker_test.cpp @@ -168,10 +168,6 @@ class DummyTransaction : public ethdb::Transaction { co_return cursor; } - boost::asio::awaitable> create_state(const core::rawdb::DatabaseReader& /* db_reader */, uint64_t /* block_number */) override { - co_return nullptr; - } - std::shared_ptr create_state(boost::asio::any_io_executor&, const core::rawdb::DatabaseReader&, uint64_t) override { return nullptr; } diff --git a/silkworm/silkrpc/ethdb/file/local_transaction.cpp b/silkworm/silkrpc/ethdb/file/local_transaction.cpp index c5977634b1..aa4ade5bd5 100644 --- a/silkworm/silkrpc/ethdb/file/local_transaction.cpp +++ b/silkworm/silkrpc/ethdb/file/local_transaction.cpp @@ -63,10 +63,6 @@ boost::asio::awaitable> LocalTransaction::get_cur co_return cursor; } -boost::asio::awaitable> LocalTransaction::create_state(const core::rawdb::DatabaseReader&, uint64_t block_number) { - co_return std::make_shared(block_number, chaindata_env_); -} - std::shared_ptr LocalTransaction::create_state(boost::asio::any_io_executor&, const core::rawdb::DatabaseReader&, uint64_t block_number) { return std::make_shared(block_number, chaindata_env_); } diff --git a/silkworm/silkrpc/ethdb/file/local_transaction.hpp b/silkworm/silkrpc/ethdb/file/local_transaction.hpp index 2cc7dff75d..fdafbdcf88 100644 --- a/silkworm/silkrpc/ethdb/file/local_transaction.hpp +++ b/silkworm/silkrpc/ethdb/file/local_transaction.hpp @@ -49,7 +49,6 @@ class LocalTransaction : public Transaction { boost::asio::awaitable> cursor_dup_sort(const std::string& table) override; - boost::asio::awaitable> create_state(const core::rawdb::DatabaseReader& db_reader, uint64_t block_number) override; std::shared_ptr create_state(boost::asio::any_io_executor& executor, const core::rawdb::DatabaseReader& db_reader, uint64_t block_number) override; boost::asio::awaitable close() override; diff --git a/silkworm/silkrpc/ethdb/kv/remote_transaction.cpp b/silkworm/silkrpc/ethdb/kv/remote_transaction.cpp index 2c8110ce11..56071a2e52 100644 --- a/silkworm/silkrpc/ethdb/kv/remote_transaction.cpp +++ b/silkworm/silkrpc/ethdb/kv/remote_transaction.cpp @@ -67,11 +67,6 @@ boost::asio::awaitable> RemoteTransaction::get_cu co_return cursor; } -boost::asio::awaitable> RemoteTransaction::create_state(const core::rawdb::DatabaseReader& db_reader, uint64_t block_number) { - auto executor = co_await boost::asio::this_coro::executor; - co_return std::make_shared(executor, db_reader, block_number); -} - std::shared_ptr RemoteTransaction::create_state(boost::asio::any_io_executor& executor, const core::rawdb::DatabaseReader& db_reader, uint64_t block_number) { return std::make_shared(executor, db_reader, block_number); } diff --git a/silkworm/silkrpc/ethdb/kv/remote_transaction.hpp b/silkworm/silkrpc/ethdb/kv/remote_transaction.hpp index d0081920e8..a563cd8e47 100644 --- a/silkworm/silkrpc/ethdb/kv/remote_transaction.hpp +++ b/silkworm/silkrpc/ethdb/kv/remote_transaction.hpp @@ -50,7 +50,6 @@ class RemoteTransaction : public Transaction { boost::asio::awaitable> cursor_dup_sort(const std::string& table) override; - boost::asio::awaitable> create_state(const core::rawdb::DatabaseReader& db_reader, uint64_t block_number) override; std::shared_ptr create_state(boost::asio::any_io_executor& executor, const core::rawdb::DatabaseReader& db_reader, uint64_t block_number) override; boost::asio::awaitable close() override; diff --git a/silkworm/silkrpc/ethdb/transaction.hpp b/silkworm/silkrpc/ethdb/transaction.hpp index 005da2095e..726e600967 100644 --- a/silkworm/silkrpc/ethdb/transaction.hpp +++ b/silkworm/silkrpc/ethdb/transaction.hpp @@ -48,7 +48,6 @@ class Transaction { virtual boost::asio::awaitable> cursor_dup_sort(const std::string& table) = 0; - virtual boost::asio::awaitable> create_state(const core::rawdb::DatabaseReader& db_reader, uint64_t block_number) = 0; virtual std::shared_ptr create_state(boost::asio::any_io_executor& executor, const core::rawdb::DatabaseReader& db_reader, uint64_t block_number) = 0; virtual boost::asio::awaitable close() = 0; diff --git a/silkworm/silkrpc/test/dummy_transaction.hpp b/silkworm/silkrpc/test/dummy_transaction.hpp index 91e43fb54b..bf25811ab6 100644 --- a/silkworm/silkrpc/test/dummy_transaction.hpp +++ b/silkworm/silkrpc/test/dummy_transaction.hpp @@ -46,11 +46,6 @@ class DummyTransaction : public ethdb::Transaction { co_return cursor_; } - boost::asio::awaitable> create_state(const core::rawdb::DatabaseReader& /* db_reader */, - uint64_t /* block_number */) override { - co_return nullptr; - } - std::shared_ptr create_state(boost::asio::any_io_executor&, const core::rawdb::DatabaseReader&, uint64_t) override { return nullptr; } diff --git a/silkworm/silkrpc/test/mock_transaction.hpp b/silkworm/silkrpc/test/mock_transaction.hpp index ad2620b118..cf1dcac2a2 100644 --- a/silkworm/silkrpc/test/mock_transaction.hpp +++ b/silkworm/silkrpc/test/mock_transaction.hpp @@ -35,8 +35,6 @@ class MockTransaction : public ethdb::Transaction { MOCK_METHOD((boost::asio::awaitable), open, ()); MOCK_METHOD((boost::asio::awaitable>), cursor, (const std::string&)); MOCK_METHOD((boost::asio::awaitable>), cursor_dup_sort, (const std::string&)); - MOCK_METHOD((boost::asio::awaitable>), create_state, - (const core::rawdb::DatabaseReader&, uint64_t)); MOCK_METHOD((std::shared_ptr), create_state, (boost::asio::any_io_executor&, const core::rawdb::DatabaseReader&, uint64_t)); MOCK_METHOD((boost::asio::awaitable), close, ());