diff options
author | cherepashka <cherepashka@yandex-team.com> | 2024-11-27 19:02:01 +0300 |
---|---|---|
committer | cherepashka <cherepashka@yandex-team.com> | 2024-11-27 19:19:13 +0300 |
commit | da01e3e90a5307aae60beecbbb94131a88d617be (patch) | |
tree | 17fefe340e7b53127443cda3281bbbc454cad7fe /yt | |
parent | 62c911c4023eaeaa30616cec70b8ec1401f73f04 (diff) | |
download | ydb-da01e3e90a5307aae60beecbbb94131a88d617be.tar.gz |
YT-21822: TTableNode's enums sizeof reductions & chunk requisition reduction
* Changelog entry
Type: feature
Component: master
Reduction of TTableNode’s size via reduction of some enums & chunk requisition
commit_hash:10541bd458cdc76723d287e8193e1a63fc7f826b
Diffstat (limited to 'yt')
-rw-r--r-- | yt/yt/client/chunk_client/public.h | 4 | ||||
-rw-r--r-- | yt/yt/client/cypress_client/public.h | 12 | ||||
-rw-r--r-- | yt/yt/client/table_client/public.h | 8 |
3 files changed, 19 insertions, 5 deletions
diff --git a/yt/yt/client/chunk_client/public.h b/yt/yt/client/chunk_client/public.h index 367fa02d36..b3b6b69b6d 100644 --- a/yt/yt/client/chunk_client/public.h +++ b/yt/yt/client/chunk_client/public.h @@ -91,7 +91,7 @@ YT_DEFINE_ERROR_ENUM( ((ReadMetaTimeout) (763)) ); -DEFINE_ENUM(EUpdateMode, +DEFINE_ENUM_WITH_UNDERLYING_TYPE(EUpdateMode, i8, ((None) (0)) ((Append) (1)) ((Overwrite) (2)) @@ -193,7 +193,7 @@ DEFINE_ENUM(EChunkAvailabilityPolicy, ); // Keep in sync with NChunkServer::ETableChunkFormat. -DEFINE_ENUM(EChunkFormat, +DEFINE_ENUM_WITH_UNDERLYING_TYPE(EChunkFormat, i8, // Sentinels. ((Unknown) (-1)) diff --git a/yt/yt/client/cypress_client/public.h b/yt/yt/client/cypress_client/public.h index 05e70d4984..a02199866e 100644 --- a/yt/yt/client/cypress_client/public.h +++ b/yt/yt/client/cypress_client/public.h @@ -22,15 +22,23 @@ using TVersionedNodeId = TVersionedObjectId; extern const TLockId NullLockId; +// TODO(cherepashka): remove after corresponding compat in 25.1 will be removed. +DEFINE_ENUM(ECompatLockMode, + ((None) (0)) + ((Snapshot) (1)) + ((Shared) (2)) + ((Exclusive) (3)) +); + // NB: The order is from weakest to strongest. -DEFINE_ENUM(ELockMode, +DEFINE_ENUM_WITH_UNDERLYING_TYPE(ELockMode, i8, ((None) (0)) ((Snapshot) (1)) ((Shared) (2)) ((Exclusive) (3)) ); -DEFINE_ENUM(ELockState, +DEFINE_ENUM_WITH_UNDERLYING_TYPE(ELockState, i8, ((Pending) (0)) ((Acquired) (1)) ); diff --git a/yt/yt/client/table_client/public.h b/yt/yt/client/table_client/public.h index e1ae0481d4..b577fb929d 100644 --- a/yt/yt/client/table_client/public.h +++ b/yt/yt/client/table_client/public.h @@ -151,7 +151,13 @@ DEFINE_ENUM(ETableSchemaMode, ((Strong) (1)) ); -DEFINE_ENUM(EOptimizeFor, +// TODO(cherepashka): remove after corresponding compat in 25.1 will be removed. +DEFINE_ENUM(ECompatOptimizeFor, + ((Lookup) (0)) + ((Scan) (1)) +); + +DEFINE_ENUM_WITH_UNDERLYING_TYPE(EOptimizeFor, int, ((Lookup) (0)) ((Scan) (1)) ); |