24#include <seastar/util/modules.hh>
30SEASTAR_MODULE_EXPORT_BEGIN
32using shard_id = unsigned;
34SEASTAR_MODULE_EXPORT_END
38#ifdef SEASTAR_BUILD_SHARED_LIBS
39shard_id* this_shard_id_ptr() noexcept;
41inline shard_id* this_shard_id_ptr() noexcept {
42 static thread_local shard_id g_this_shard_id;
43 return &g_this_shard_id;
49SEASTAR_MODULE_EXPORT_BEGIN
53 return *internal::this_shard_id_ptr();
56SEASTAR_MODULE_EXPORT_END
Seastar API namespace.
Definition: abort_on_ebadf.hh:26
shard_id this_shard_id() noexcept
Returns shard_id of the of the current shard.
Definition: shard_id.hh:52