Files
scylladb/db/virtual_tables.hh
Pavel Emelyanov a1ea553fe1 code: Replace distributed<> with sharded<>
The latter is recommended in seastar, and the former was left as
compatibility alias. Latest seastar explicitly marks it as deprecated so
once the submodule is updated, compilation logs will explode.

Most of the patch is generated with

    for f in $(git grep -l '\<distributed<[A-Za-z0-9:_]*>') ; do sed -e 's/\<distributed<\([A-Za-z0-9:_]*\)>/sharded<\1>/g' -i $f; done
    for f in $(git grep -l distributed.hh); do sed -e 's/distributed.hh/sharded.hh/' -i $f ; done

and a small manual change in test/perf/perf.hh

Signed-off-by: Pavel Emelyanov <xemul@scylladb.com>

Closes scylladb/scylladb#26136
2025-09-19 12:22:51 +02:00

62 lines
1.2 KiB
C++

/*
* Modified by ScyllaDB
* Copyright (C) 2023-present ScyllaDB
*/
/*
* SPDX-License-Identifier: (LicenseRef-ScyllaDB-Source-Available-1.0 and Apache-2.0)
*/
#pragma once
#include <seastar/core/sharded.hh>
#include <map>
#include "schema/schema_fwd.hh"
namespace replica {
class database;
}
namespace service {
class storage_service;
class raft_group_registry;
class tablet_allocator;
}
namespace gms {
class gossiper;
}
namespace netw {
class messaging_service;
}
namespace db {
class config;
class system_keyspace;
future<> initialize_virtual_tables(
sharded<replica::database>&,
sharded<service::storage_service>&,
sharded<gms::gossiper>&,
sharded<service::raft_group_registry>&,
sharded<db::system_keyspace>&,
sharded<service::tablet_allocator>&,
sharded<netw::messaging_service>&,
db::config&);
class virtual_table;
using virtual_tables_registry_impl = std::map<table_id, std::unique_ptr<virtual_table>>;
// Pimpl to hide virtual_table from the rest of the code
class virtual_tables_registry : public std::unique_ptr<virtual_tables_registry_impl> {
public:
virtual_tables_registry();
~virtual_tables_registry();
};
} // namespace db