ydb-embedded-ui 22.2.0 → 22.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (405) hide show
  1. package/dist/components/DiskCapacityInfo/DiskCapacityInfo.d.ts +10 -1
  2. package/dist/components/DiskCapacityInfo/DiskCapacityInfo.js +75 -13
  3. package/dist/components/DiskCapacityInfo/DiskCapacityInfo.js.map +1 -1
  4. package/dist/components/DiskCapacityInfo/i18n/index.d.ts +1 -1
  5. package/dist/components/DiskPopup/DiskPopup.d.ts +25 -0
  6. package/dist/components/DiskPopup/DiskPopup.js +44 -0
  7. package/dist/components/DiskPopup/DiskPopup.js.map +1 -0
  8. package/dist/components/DiskPopup/DiskPopup.scss +203 -0
  9. package/dist/components/DiskPopup/i18n/en.json +3 -0
  10. package/dist/components/DiskPopup/i18n/index.d.ts +2 -0
  11. package/dist/components/DiskPopup/i18n/index.js +4 -0
  12. package/dist/components/DiskPopup/i18n/index.js.map +1 -0
  13. package/dist/components/DiskStatus/DiskStatus.d.ts +31 -0
  14. package/dist/components/DiskStatus/DiskStatus.js +61 -0
  15. package/dist/components/DiskStatus/DiskStatus.js.map +1 -0
  16. package/dist/components/DiskStatus/DiskStatus.scss +59 -0
  17. package/dist/components/DiskStatus/i18n/en.json +6 -0
  18. package/dist/components/DiskStatus/i18n/index.d.ts +2 -0
  19. package/dist/components/DiskStatus/i18n/index.js +4 -0
  20. package/dist/components/DiskStatus/i18n/index.js.map +1 -0
  21. package/dist/components/EntityStatus/EntityStatus.d.ts +1 -0
  22. package/dist/components/EntityStatus/EntityStatus.js +1 -1
  23. package/dist/components/EntityStatus/EntityStatus.js.map +1 -1
  24. package/dist/components/EvictVDiskButton/i18n/en.json +1 -1
  25. package/dist/components/FullNodeViewer/i18n/index.d.ts +1 -1
  26. package/dist/components/Graph/GravityGraph.js +9 -2
  27. package/dist/components/Graph/GravityGraph.js.map +1 -1
  28. package/dist/components/Graph/utils.d.ts +2 -1
  29. package/dist/components/Graph/utils.js +7 -0
  30. package/dist/components/Graph/utils.js.map +1 -1
  31. package/dist/components/HoverPopup/HoverPopup.d.ts +2 -1
  32. package/dist/components/HoverPopup/HoverPopup.js +49 -17
  33. package/dist/components/HoverPopup/HoverPopup.js.map +1 -1
  34. package/dist/components/HoverPopup/usePopupPriority.d.ts +4 -0
  35. package/dist/components/HoverPopup/usePopupPriority.js +30 -0
  36. package/dist/components/HoverPopup/usePopupPriority.js.map +1 -0
  37. package/dist/components/PDiskInfo/PDiskLogSize.d.ts +5 -0
  38. package/dist/components/PDiskInfo/PDiskLogSize.js +20 -0
  39. package/dist/components/PDiskInfo/PDiskLogSize.js.map +1 -0
  40. package/dist/components/PDiskInfo/PDiskLogSize.scss +12 -0
  41. package/dist/components/PDiskInfo/getPDiskDetails.d.ts +4 -0
  42. package/dist/components/PDiskInfo/getPDiskDetails.js +33 -0
  43. package/dist/components/PDiskInfo/getPDiskDetails.js.map +1 -0
  44. package/dist/components/PDiskInfo/i18n/en.json +64 -2
  45. package/dist/components/PDiskInfo/i18n/index.d.ts +1 -1
  46. package/dist/components/PDiskInfo/statuses.d.ts +7 -0
  47. package/dist/components/PDiskInfo/statuses.js +185 -0
  48. package/dist/components/PDiskInfo/statuses.js.map +1 -0
  49. package/dist/components/PDiskPopup/PDiskPopup.d.ts +4 -7
  50. package/dist/components/PDiskPopup/PDiskPopup.js +28 -99
  51. package/dist/components/PDiskPopup/PDiskPopup.js.map +1 -1
  52. package/dist/components/PDiskPopup/i18n/en.json +2 -12
  53. package/dist/components/PDiskPopup/i18n/index.d.ts +1 -1
  54. package/dist/components/PaginatedTable/rowLookup.js +30 -9
  55. package/dist/components/PaginatedTable/rowLookup.js.map +1 -1
  56. package/dist/components/StorageGroupInfo/StorageGroupInfo.d.ts +3 -3
  57. package/dist/components/StorageGroupInfo/StorageGroupInfo.js +78 -218
  58. package/dist/components/StorageGroupInfo/StorageGroupInfo.js.map +1 -1
  59. package/dist/components/StorageGroupInfo/StorageGroupInfo.scss +21 -0
  60. package/dist/components/StorageGroupInfo/i18n/en.json +1 -9
  61. package/dist/components/StorageGroupInfo/i18n/index.d.ts +1 -1
  62. package/dist/components/TableKeyboardNavigation/TableKeyboardNavigation.js +5 -1
  63. package/dist/components/TableKeyboardNavigation/TableKeyboardNavigation.js.map +1 -1
  64. package/dist/components/VDisk/VDisk.d.ts +2 -1
  65. package/dist/components/VDisk/VDisk.js +23 -32
  66. package/dist/components/VDisk/VDisk.js.map +1 -1
  67. package/dist/components/VDisk/VDiskWithDonorsStack.d.ts +1 -1
  68. package/dist/components/VDisk/VDiskWithDonorsStack.js +2 -1
  69. package/dist/components/VDisk/VDiskWithDonorsStack.js.map +1 -1
  70. package/dist/components/VDisk/getFlagStatusText.d.ts +2 -0
  71. package/dist/components/VDisk/getFlagStatusText.js +18 -0
  72. package/dist/components/VDisk/getFlagStatusText.js.map +1 -0
  73. package/dist/components/VDisk/i18n/en.json +1 -1
  74. package/dist/components/VDisk/i18n/index.d.ts +1 -1
  75. package/dist/components/VDiskInfo/getVDiskDetails.d.ts +5 -0
  76. package/dist/components/VDiskInfo/getVDiskDetails.js +29 -0
  77. package/dist/components/VDiskInfo/getVDiskDetails.js.map +1 -0
  78. package/dist/components/VDiskInfo/i18n/en.json +3 -1
  79. package/dist/components/VDiskInfo/i18n/index.d.ts +1 -1
  80. package/dist/components/VDiskPopup/VDiskPopup.d.ts +6 -8
  81. package/dist/components/VDiskPopup/VDiskPopup.js +106 -240
  82. package/dist/components/VDiskPopup/VDiskPopup.js.map +1 -1
  83. package/dist/components/VDiskPopup/VDiskPopup.scss +3 -10
  84. package/dist/components/VDiskPopup/i18n/en.json +6 -22
  85. package/dist/components/VDiskPopup/i18n/index.d.ts +1 -1
  86. package/dist/components/VDiskStatus/VDiskReplicationStatus.d.ts +8 -0
  87. package/dist/components/VDiskStatus/VDiskReplicationStatus.js +32 -0
  88. package/dist/components/VDiskStatus/VDiskReplicationStatus.js.map +1 -0
  89. package/dist/components/VDiskStatus/VDiskStatus.d.ts +16 -0
  90. package/dist/components/VDiskStatus/VDiskStatus.js +20 -0
  91. package/dist/components/VDiskStatus/VDiskStatus.js.map +1 -0
  92. package/dist/components/VDiskStatus/VDiskStatus.scss +32 -0
  93. package/dist/components/VDiskStatus/i18n/en.json +33 -0
  94. package/dist/components/VDiskStatus/i18n/index.d.ts +1 -0
  95. package/dist/components/VDiskStatus/i18n/index.js +5 -0
  96. package/dist/components/VDiskStatus/i18n/index.js.map +1 -0
  97. package/dist/components/VDiskStatus/index.d.ts +2 -0
  98. package/dist/components/VDiskStatus/index.js +3 -0
  99. package/dist/components/VDiskStatus/index.js.map +1 -0
  100. package/dist/components/VDiskStatus/statuses.d.ts +4 -0
  101. package/dist/components/VDiskStatus/statuses.js +120 -0
  102. package/dist/components/VDiskStatus/statuses.js.map +1 -0
  103. package/dist/components/capacityMetricsColumns/i18n/en.json +4 -4
  104. package/dist/containers/Authentication/Authentication.js +29 -30
  105. package/dist/containers/Authentication/Authentication.js.map +1 -1
  106. package/dist/containers/Authentication/utils.d.ts +2 -2
  107. package/dist/containers/Authentication/utils.js +1 -1
  108. package/dist/containers/Authentication/utils.js.map +1 -1
  109. package/dist/containers/Cluster/ClusterDrawerHealthcheck.js +6 -1
  110. package/dist/containers/Cluster/ClusterDrawerHealthcheck.js.map +1 -1
  111. package/dist/containers/Clusters/ClusterDrawerHealthcheck.js +1 -1
  112. package/dist/containers/Clusters/ClusterDrawerHealthcheck.js.map +1 -1
  113. package/dist/containers/Header/Header.js +8 -2
  114. package/dist/containers/Header/Header.js.map +1 -1
  115. package/dist/containers/Header/StorageGroupLeftControls.d.ts +1 -0
  116. package/dist/containers/Header/StorageGroupLeftControls.js +23 -0
  117. package/dist/containers/Header/StorageGroupLeftControls.js.map +1 -0
  118. package/dist/containers/Header/i18n/en.json +3 -1
  119. package/dist/containers/Header/i18n/index.d.ts +1 -1
  120. package/dist/containers/Operations/constants.d.ts +1 -1
  121. package/dist/containers/PDiskPage/PDiskSpaceDistribution/PDiskSpaceDistribution.js +4 -4
  122. package/dist/containers/PDiskPage/PDiskSpaceDistribution/PDiskSpaceDistribution.js.map +1 -1
  123. package/dist/containers/PDiskPage/i18n/index.d.ts +1 -1
  124. package/dist/containers/Storage/Disks/Disks.js +36 -9
  125. package/dist/containers/Storage/Disks/Disks.js.map +1 -1
  126. package/dist/containers/Storage/PDisk/PDisk.d.ts +2 -1
  127. package/dist/containers/Storage/PDisk/PDisk.js +2 -2
  128. package/dist/containers/Storage/PDisk/PDisk.js.map +1 -1
  129. package/dist/containers/Storage/PDisk/i18n/index.d.ts +1 -1
  130. package/dist/containers/Storage/PaginatedStorageGroupsTable/columns/columns.js +7 -2
  131. package/dist/containers/Storage/PaginatedStorageGroupsTable/columns/columns.js.map +1 -1
  132. package/dist/containers/Storage/PaginatedStorageGroupsTable/columns/i18n/index.d.ts +1 -1
  133. package/dist/containers/Storage/StorageExpertModePanel/components/SpaceLegend.scss +14 -82
  134. package/dist/containers/Storage/StorageExpertModePanel/i18n/index.d.ts +1 -1
  135. package/dist/containers/Storage/StorageGroupStateLabel.d.ts +4 -0
  136. package/dist/containers/Storage/StorageGroupStateLabel.js +9 -0
  137. package/dist/containers/Storage/StorageGroupStateLabel.js.map +1 -0
  138. package/dist/containers/Storage/utils/getStorageGroupStateLabel.d.ts +2 -0
  139. package/dist/containers/Storage/utils/getStorageGroupStateLabel.js +35 -0
  140. package/dist/containers/Storage/utils/getStorageGroupStateLabel.js.map +1 -0
  141. package/dist/containers/StorageGroupPage/StorageGroupPage.js +17 -12
  142. package/dist/containers/StorageGroupPage/StorageGroupPage.js.map +1 -1
  143. package/dist/containers/StorageGroupPage/StorageGroupPage.scss +9 -13
  144. package/dist/containers/StorageGroupPage/i18n/en.json +3 -1
  145. package/dist/containers/StorageGroupPage/i18n/index.d.ts +1 -1
  146. package/dist/containers/Tenant/Diagnostics/DiagnosticsPages.js +5 -1
  147. package/dist/containers/Tenant/Diagnostics/DiagnosticsPages.js.map +1 -1
  148. package/dist/containers/Tenant/Diagnostics/Overview/Overview.d.ts +2 -1
  149. package/dist/containers/Tenant/Diagnostics/Overview/Overview.js +11 -2
  150. package/dist/containers/Tenant/Diagnostics/Overview/Overview.js.map +1 -1
  151. package/dist/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/ResourcePoolInfo.scss +24 -0
  152. package/dist/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/ResourcePoolUsage.d.ts +8 -0
  153. package/dist/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/ResourcePoolUsage.js +34 -0
  154. package/dist/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/ResourcePoolUsage.js.map +1 -0
  155. package/dist/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/i18n/en.json +4 -1
  156. package/dist/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/i18n/index.d.ts +1 -1
  157. package/dist/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/index.d.ts +1 -0
  158. package/dist/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/index.js +1 -0
  159. package/dist/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/index.js.map +1 -1
  160. package/dist/containers/Tenant/Diagnostics/Overview/SchemaObjectInfo/SchemaObjectInfo.d.ts +2 -1
  161. package/dist/containers/Tenant/Diagnostics/Overview/SchemaObjectInfo/SchemaObjectInfo.js +12 -3
  162. package/dist/containers/Tenant/Diagnostics/Overview/SchemaObjectInfo/SchemaObjectInfo.js.map +1 -1
  163. package/dist/containers/Tenant/Diagnostics/Overview/SchemaObjectInfo/prepareSchemaObjectInfo.d.ts +2 -1
  164. package/dist/containers/Tenant/Diagnostics/Overview/SchemaObjectInfo/prepareSchemaObjectInfo.js +9 -8
  165. package/dist/containers/Tenant/Diagnostics/Overview/SchemaObjectInfo/prepareSchemaObjectInfo.js.map +1 -1
  166. package/dist/containers/Tenant/Diagnostics/Overview/StreamingQueryInfo/StreamingQueryInfo.d.ts +16 -1
  167. package/dist/containers/Tenant/Diagnostics/Overview/StreamingQueryInfo/StreamingQueryInfo.js +55 -33
  168. package/dist/containers/Tenant/Diagnostics/Overview/StreamingQueryInfo/StreamingQueryInfo.js.map +1 -1
  169. package/dist/containers/Tenant/Diagnostics/Overview/StreamingQueryInfo/i18n/en.json +5 -1
  170. package/dist/containers/Tenant/Diagnostics/Overview/StreamingQueryInfo/i18n/index.d.ts +1 -1
  171. package/dist/containers/Tenant/Diagnostics/Overview/TableInfo/i18n/en.json +4 -0
  172. package/dist/containers/Tenant/Diagnostics/Overview/TableInfo/i18n/index.d.ts +1 -1
  173. package/dist/containers/Tenant/Diagnostics/Overview/TableInfo/prepareTableInfo/prepareColumnTableInfo.js +4 -1
  174. package/dist/containers/Tenant/Diagnostics/Overview/TableInfo/prepareTableInfo/prepareColumnTableInfo.js.map +1 -1
  175. package/dist/containers/Tenant/Diagnostics/Overview/TableInfo/prepareTableInfo/prepareRowTableInfo.js +4 -1
  176. package/dist/containers/Tenant/Diagnostics/Overview/TableInfo/prepareTableInfo/prepareRowTableInfo.js.map +1 -1
  177. package/dist/containers/Tenant/Diagnostics/Overview/TableInfo/prepareTableInfo/prepareTTL.js +41 -3
  178. package/dist/containers/Tenant/Diagnostics/Overview/TableInfo/prepareTableInfo/prepareTTL.js.map +1 -1
  179. package/dist/containers/Tenant/Diagnostics/StreamingQueryGraph/StreamingQueryGraph.d.ts +7 -0
  180. package/dist/containers/Tenant/Diagnostics/StreamingQueryGraph/StreamingQueryGraph.js +38 -0
  181. package/dist/containers/Tenant/Diagnostics/StreamingQueryGraph/StreamingQueryGraph.js.map +1 -0
  182. package/dist/containers/Tenant/Diagnostics/StreamingQueryGraph/StreamingQueryGraph.scss +18 -0
  183. package/dist/containers/Tenant/Diagnostics/StreamingQueryGraph/i18n/en.json +5 -0
  184. package/dist/containers/Tenant/Diagnostics/StreamingQueryGraph/i18n/index.d.ts +2 -0
  185. package/dist/containers/Tenant/Diagnostics/StreamingQueryGraph/i18n/index.js +5 -0
  186. package/dist/containers/Tenant/Diagnostics/StreamingQueryGraph/i18n/index.js.map +1 -0
  187. package/dist/containers/Tenant/Diagnostics/StreamingQueryGraph/index.d.ts +1 -0
  188. package/dist/containers/Tenant/Diagnostics/StreamingQueryGraph/index.js +2 -0
  189. package/dist/containers/Tenant/Diagnostics/StreamingQueryGraph/index.js.map +1 -0
  190. package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantStorage/i18n/index.d.ts +1 -1
  191. package/dist/containers/Tenant/Diagnostics/i18n/en.json +1 -0
  192. package/dist/containers/Tenant/Diagnostics/i18n/index.d.ts +1 -1
  193. package/dist/containers/Tenant/Diagnostics/tabsContent.js +2 -0
  194. package/dist/containers/Tenant/Diagnostics/tabsContent.js.map +1 -1
  195. package/dist/containers/Tenant/Healthcheck/components/HealthcheckDrawer.d.ts +3 -1
  196. package/dist/containers/Tenant/Healthcheck/components/HealthcheckDrawer.js +3 -3
  197. package/dist/containers/Tenant/Healthcheck/components/HealthcheckDrawer.js.map +1 -1
  198. package/dist/containers/Tenant/Query/QueryEditor/YqlEditor/YqlEditor.js +8 -1
  199. package/dist/containers/Tenant/Query/QueryEditor/YqlEditor/YqlEditor.js.map +1 -1
  200. package/dist/containers/Tenant/TenantDrawerHealthcheck.js +8 -1
  201. package/dist/containers/Tenant/TenantDrawerHealthcheck.js.map +1 -1
  202. package/dist/containers/Tenants/DatabaseDrawerHealthcheck.js +8 -1
  203. package/dist/containers/Tenants/DatabaseDrawerHealthcheck.js.map +1 -1
  204. package/dist/containers/VDiskPage/i18n/index.d.ts +1 -1
  205. package/dist/lib.d.ts +1 -1
  206. package/dist/lib.js.map +1 -1
  207. package/dist/store/configureStore.d.ts +2 -2
  208. package/dist/store/defaultStore.d.ts +1 -1
  209. package/dist/store/reducers/executeTopQueries/executeTopQueries.d.ts +7 -0
  210. package/dist/store/reducers/executeTopQueries/executeTopQueries.js +38 -0
  211. package/dist/store/reducers/executeTopQueries/executeTopQueries.js.map +1 -1
  212. package/dist/store/reducers/header/types.d.ts +1 -1
  213. package/dist/store/reducers/index.d.ts +2 -2
  214. package/dist/store/reducers/pdisk/types.d.ts +1 -0
  215. package/dist/store/reducers/pdisk/utils.js +6 -1
  216. package/dist/store/reducers/pdisk/utils.js.map +1 -1
  217. package/dist/store/reducers/query/parsers/prepareStreamingQueryPlan.d.ts +8 -0
  218. package/dist/store/reducers/query/parsers/prepareStreamingQueryPlan.js +53 -0
  219. package/dist/store/reducers/query/parsers/prepareStreamingQueryPlan.js.map +1 -0
  220. package/dist/store/reducers/storage/prepareGroupsDisks.d.ts +1 -0
  221. package/dist/store/reducers/storage/prepareGroupsDisks.js +7 -18
  222. package/dist/store/reducers/storage/prepareGroupsDisks.js.map +1 -1
  223. package/dist/store/reducers/storage/utils.js +4 -0
  224. package/dist/store/reducers/storage/utils.js.map +1 -1
  225. package/dist/store/reducers/streamingQuery/streamingQuery.d.ts +5 -1
  226. package/dist/store/reducers/streamingQuery/streamingQuery.js +36 -13
  227. package/dist/store/reducers/streamingQuery/streamingQuery.js.map +1 -1
  228. package/dist/store/reducers/tenant/constants.d.ts +1 -0
  229. package/dist/store/reducers/tenant/constants.js +1 -0
  230. package/dist/store/reducers/tenant/constants.js.map +1 -1
  231. package/dist/styles/mixins.scss +22 -0
  232. package/dist/types/api/pdisk.d.ts +4 -0
  233. package/dist/types/api/pdisk.js.map +1 -1
  234. package/dist/types/api/schema/columnEntity.d.ts +2 -1
  235. package/dist/types/api/schema/sysView.d.ts +59 -2
  236. package/dist/types/api/schema/sysView.js +53 -1
  237. package/dist/types/api/schema/sysView.js.map +1 -1
  238. package/dist/types/api/schema/table.d.ts +8 -0
  239. package/dist/types/api/schema/table.js.map +1 -1
  240. package/dist/types/api/vdisk.d.ts +8 -0
  241. package/dist/types/api/vdisk.js +7 -0
  242. package/dist/types/api/vdisk.js.map +1 -1
  243. package/dist/types/store/nodesList.d.ts +4 -2
  244. package/dist/uiFactory/types.d.ts +5 -2
  245. package/dist/utils/bytesParsers/formatBytes.d.ts +3 -1
  246. package/dist/utils/bytesParsers/formatBytes.js +12 -3
  247. package/dist/utils/bytesParsers/formatBytes.js.map +1 -1
  248. package/dist/utils/disks/constants.d.ts +1 -0
  249. package/dist/utils/disks/constants.js +4 -0
  250. package/dist/utils/disks/constants.js.map +1 -1
  251. package/dist/utils/disks/diskInfo/getDiskLocationItems.d.ts +16 -0
  252. package/dist/utils/disks/diskInfo/getDiskLocationItems.js +30 -0
  253. package/dist/utils/disks/diskInfo/getDiskLocationItems.js.map +1 -0
  254. package/dist/utils/disks/diskInfo/i18n/en.json +9 -0
  255. package/dist/utils/disks/diskInfo/i18n/index.d.ts +2 -0
  256. package/dist/utils/disks/diskInfo/i18n/index.js +4 -0
  257. package/dist/utils/disks/diskInfo/i18n/index.js.map +1 -0
  258. package/dist/utils/disks/iconCalculators.d.ts +5 -0
  259. package/dist/utils/disks/iconCalculators.js +1 -1
  260. package/dist/utils/disks/iconCalculators.js.map +1 -1
  261. package/dist/utils/disks/prepareDisks.d.ts +6 -2
  262. package/dist/utils/disks/prepareDisks.js +22 -35
  263. package/dist/utils/disks/prepareDisks.js.map +1 -1
  264. package/dist/utils/disks/types.d.ts +9 -2
  265. package/dist/utils/hooks/useNodeMetadata.d.ts +2 -0
  266. package/dist/utils/hooks/useNodeMetadata.js +15 -0
  267. package/dist/utils/hooks/useNodeMetadata.js.map +1 -0
  268. package/dist/utils/nodes.js +6 -2
  269. package/dist/utils/nodes.js.map +1 -1
  270. package/dist/utils/query.d.ts +1 -0
  271. package/dist/utils/query.js +40 -0
  272. package/dist/utils/query.js.map +1 -1
  273. package/dist/utils/schema.d.ts +6 -2
  274. package/dist/utils/schema.js +14 -4
  275. package/dist/utils/schema.js.map +1 -1
  276. package/dist/utils/storageMetrics.d.ts +2 -2
  277. package/dist/utils/storageMetrics.js +22 -10
  278. package/dist/utils/storageMetrics.js.map +1 -1
  279. package/dist/utils/timeParsers/formatDuration.d.ts +4 -1
  280. package/dist/utils/timeParsers/formatDuration.js +16 -1
  281. package/dist/utils/timeParsers/formatDuration.js.map +1 -1
  282. package/dist/utils/timeParsers/i18n/en.json +5 -1
  283. package/dist/utils/timeParsers/i18n/index.d.ts +1 -1
  284. package/dist/utils/timeParsers/i18n/ru.json +5 -1
  285. package/package.json +2 -2
  286. package/src/components/DiskCapacityInfo/DiskCapacityInfo.tsx +106 -15
  287. package/src/components/DiskPopup/DiskPopup.scss +203 -0
  288. package/src/components/DiskPopup/DiskPopup.tsx +123 -0
  289. package/src/components/DiskPopup/i18n/en.json +3 -0
  290. package/src/components/DiskPopup/i18n/index.ts +5 -0
  291. package/src/components/DiskStatus/DiskStatus.scss +59 -0
  292. package/src/components/DiskStatus/DiskStatus.tsx +149 -0
  293. package/src/components/DiskStatus/i18n/en.json +6 -0
  294. package/src/components/DiskStatus/i18n/index.ts +5 -0
  295. package/src/components/EntityStatus/EntityStatus.tsx +1 -1
  296. package/src/components/EvictVDiskButton/i18n/en.json +1 -1
  297. package/src/components/Graph/GravityGraph.tsx +9 -2
  298. package/src/components/Graph/utils.ts +9 -1
  299. package/src/components/HoverPopup/HoverPopup.tsx +67 -20
  300. package/src/components/HoverPopup/usePopupPriority.ts +39 -0
  301. package/src/components/PDiskInfo/PDiskLogSize.scss +12 -0
  302. package/src/components/PDiskInfo/PDiskLogSize.tsx +37 -0
  303. package/src/components/PDiskInfo/getPDiskDetails.tsx +37 -0
  304. package/src/components/PDiskInfo/i18n/en.json +64 -8
  305. package/src/components/PDiskInfo/statuses.ts +209 -0
  306. package/src/components/PDiskPopup/PDiskPopup.tsx +62 -147
  307. package/src/components/PDiskPopup/i18n/en.json +2 -12
  308. package/src/components/PaginatedTable/rowLookup.ts +35 -10
  309. package/src/components/StorageGroupInfo/StorageGroupInfo.scss +21 -0
  310. package/src/components/StorageGroupInfo/StorageGroupInfo.tsx +121 -260
  311. package/src/components/StorageGroupInfo/i18n/en.json +1 -9
  312. package/src/components/TableKeyboardNavigation/TableKeyboardNavigation.tsx +5 -1
  313. package/src/components/VDisk/VDisk.tsx +31 -34
  314. package/src/components/VDisk/VDiskWithDonorsStack.tsx +2 -0
  315. package/src/components/VDisk/getFlagStatusText.ts +19 -0
  316. package/src/components/VDisk/i18n/en.json +1 -1
  317. package/src/components/VDiskInfo/getVDiskDetails.tsx +41 -0
  318. package/src/components/VDiskInfo/i18n/en.json +3 -10
  319. package/src/components/VDiskPopup/VDiskPopup.scss +3 -10
  320. package/src/components/VDiskPopup/VDiskPopup.tsx +197 -421
  321. package/src/components/VDiskPopup/i18n/en.json +6 -22
  322. package/src/components/VDiskStatus/VDiskReplicationStatus.tsx +77 -0
  323. package/src/components/VDiskStatus/VDiskStatus.scss +32 -0
  324. package/src/components/VDiskStatus/VDiskStatus.tsx +38 -0
  325. package/src/components/VDiskStatus/i18n/en.json +33 -0
  326. package/src/components/VDiskStatus/i18n/index.ts +7 -0
  327. package/src/components/VDiskStatus/index.ts +7 -0
  328. package/src/components/VDiskStatus/statuses.ts +139 -0
  329. package/src/components/capacityMetricsColumns/i18n/en.json +4 -4
  330. package/src/containers/Authentication/Authentication.tsx +29 -34
  331. package/src/containers/Authentication/utils.ts +3 -3
  332. package/src/containers/Cluster/ClusterDrawerHealthcheck.tsx +6 -0
  333. package/src/containers/Clusters/ClusterDrawerHealthcheck.tsx +1 -0
  334. package/src/containers/Header/Header.tsx +11 -3
  335. package/src/containers/Header/StorageGroupLeftControls.tsx +38 -0
  336. package/src/containers/Header/i18n/en.json +3 -1
  337. package/src/containers/PDiskPage/PDiskSpaceDistribution/PDiskSpaceDistribution.tsx +13 -2
  338. package/src/containers/Storage/Disks/Disks.tsx +66 -12
  339. package/src/containers/Storage/PDisk/PDisk.tsx +3 -0
  340. package/src/containers/Storage/PaginatedStorageGroupsTable/columns/columns.tsx +24 -3
  341. package/src/containers/Storage/StorageExpertModePanel/components/SpaceLegend.scss +14 -82
  342. package/src/containers/Storage/StorageGroupStateLabel.tsx +22 -0
  343. package/src/containers/Storage/utils/getStorageGroupStateLabel.ts +49 -0
  344. package/src/containers/StorageGroupPage/StorageGroupPage.scss +9 -13
  345. package/src/containers/StorageGroupPage/StorageGroupPage.tsx +53 -25
  346. package/src/containers/StorageGroupPage/i18n/en.json +3 -1
  347. package/src/containers/Tenant/Diagnostics/DiagnosticsPages.ts +6 -1
  348. package/src/containers/Tenant/Diagnostics/Overview/Overview.tsx +22 -2
  349. package/src/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/ResourcePoolInfo.scss +24 -0
  350. package/src/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/ResourcePoolUsage.tsx +53 -0
  351. package/src/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/i18n/en.json +4 -1
  352. package/src/containers/Tenant/Diagnostics/Overview/ResourcePoolInfo/index.ts +1 -0
  353. package/src/containers/Tenant/Diagnostics/Overview/SchemaObjectInfo/SchemaObjectInfo.tsx +19 -2
  354. package/src/containers/Tenant/Diagnostics/Overview/SchemaObjectInfo/prepareSchemaObjectInfo.tsx +11 -10
  355. package/src/containers/Tenant/Diagnostics/Overview/StreamingQueryInfo/StreamingQueryInfo.tsx +79 -34
  356. package/src/containers/Tenant/Diagnostics/Overview/StreamingQueryInfo/i18n/en.json +5 -1
  357. package/src/containers/Tenant/Diagnostics/Overview/TableInfo/i18n/en.json +4 -0
  358. package/src/containers/Tenant/Diagnostics/Overview/TableInfo/prepareTableInfo/prepareColumnTableInfo.tsx +11 -1
  359. package/src/containers/Tenant/Diagnostics/Overview/TableInfo/prepareTableInfo/prepareRowTableInfo.tsx +11 -1
  360. package/src/containers/Tenant/Diagnostics/Overview/TableInfo/prepareTableInfo/prepareTTL.ts +45 -3
  361. package/src/containers/Tenant/Diagnostics/StreamingQueryGraph/StreamingQueryGraph.scss +18 -0
  362. package/src/containers/Tenant/Diagnostics/StreamingQueryGraph/StreamingQueryGraph.tsx +79 -0
  363. package/src/containers/Tenant/Diagnostics/StreamingQueryGraph/i18n/en.json +5 -0
  364. package/src/containers/Tenant/Diagnostics/StreamingQueryGraph/i18n/index.ts +7 -0
  365. package/src/containers/Tenant/Diagnostics/StreamingQueryGraph/index.ts +1 -0
  366. package/src/containers/Tenant/Diagnostics/i18n/en.json +1 -0
  367. package/src/containers/Tenant/Diagnostics/tabsContent.tsx +4 -0
  368. package/src/containers/Tenant/Healthcheck/components/HealthcheckDrawer.tsx +5 -2
  369. package/src/containers/Tenant/Query/QueryEditor/YqlEditor/YqlEditor.tsx +8 -1
  370. package/src/containers/Tenant/TenantDrawerHealthcheck.tsx +10 -0
  371. package/src/containers/Tenants/DatabaseDrawerHealthcheck.tsx +10 -0
  372. package/src/lib.ts +1 -0
  373. package/src/store/reducers/executeTopQueries/executeTopQueries.ts +46 -0
  374. package/src/store/reducers/header/types.ts +3 -1
  375. package/src/store/reducers/pdisk/types.ts +1 -0
  376. package/src/store/reducers/pdisk/utils.ts +6 -3
  377. package/src/store/reducers/query/parsers/prepareStreamingQueryPlan.ts +74 -0
  378. package/src/store/reducers/storage/prepareGroupsDisks.ts +7 -22
  379. package/src/store/reducers/storage/utils.ts +4 -0
  380. package/src/store/reducers/streamingQuery/streamingQuery.ts +44 -19
  381. package/src/store/reducers/tenant/constants.ts +1 -0
  382. package/src/styles/mixins.scss +22 -0
  383. package/src/types/api/pdisk.ts +4 -0
  384. package/src/types/api/schema/columnEntity.ts +2 -1
  385. package/src/types/api/schema/sysView.ts +60 -37
  386. package/src/types/api/schema/table.ts +7 -0
  387. package/src/types/api/vdisk.ts +9 -0
  388. package/src/types/store/nodesList.ts +7 -7
  389. package/src/uiFactory/types.ts +9 -2
  390. package/src/utils/bytesParsers/formatBytes.ts +23 -4
  391. package/src/utils/disks/constants.ts +5 -0
  392. package/src/utils/disks/diskInfo/getDiskLocationItems.ts +50 -0
  393. package/src/utils/disks/diskInfo/i18n/en.json +9 -0
  394. package/src/utils/disks/diskInfo/i18n/index.ts +5 -0
  395. package/src/utils/disks/iconCalculators.ts +1 -1
  396. package/src/utils/disks/prepareDisks.ts +21 -47
  397. package/src/utils/disks/types.ts +10 -2
  398. package/src/utils/hooks/useNodeMetadata.ts +21 -0
  399. package/src/utils/nodes.ts +6 -1
  400. package/src/utils/query.ts +55 -0
  401. package/src/utils/schema.ts +22 -5
  402. package/src/utils/storageMetrics.ts +27 -14
  403. package/src/utils/timeParsers/formatDuration.ts +22 -1
  404. package/src/utils/timeParsers/i18n/en.json +5 -1
  405. package/src/utils/timeParsers/i18n/ru.json +5 -1
@@ -1,26 +1,10 @@
1
1
  {
2
- "context_not-available": "Not available",
3
- "label_storage-pool": "StoragePool",
4
- "label_donor": "Donor",
5
- "label_node-id": "NodeId",
6
- "label_pdisk-id": "PDiskId",
7
- "label_vslot-id": "VSlotId",
8
- "label_links": "Links",
2
+ "label_storage-pool": "Storage Pool Name",
9
3
  "label_vdisk": "VDisk",
10
- "label_fresh": "Fresh",
11
- "label_level": "Level",
12
- "label_space": "Space",
13
- "label_front-queues": "FrontQueues",
14
- "label_replicated": "Replicated",
15
- "label_progress": "Progress",
16
- "label_remaining": "Remaining",
17
- "label_unsync-vdisks": "UnsyncVDisks",
18
- "label_allocated": "Allocated",
19
- "label_available": "Available",
20
- "label_read": "Read",
21
- "label_write": "Write",
22
- "label_replication": "Replication",
23
- "label_recipient": "Recipient",
4
+ "label_front-queues": "Front Queues",
5
+ "label_read": "Read Throughput",
6
+ "label_write": "Write Throughput",
24
7
  "action_open-in-developer-ui": "Open in Developer UI",
25
- "action_go-to-vdisk": "Go to VDisk"
8
+ "action_go-to-vdisk": "Go to VDisk",
9
+ "label_compaction": "Compaction"
26
10
  }
@@ -0,0 +1,77 @@
1
+ import React from 'react';
2
+
3
+ import type {LabelProps} from '@gravity-ui/uikit';
4
+ import {Flex, Progress} from '@gravity-ui/uikit';
5
+
6
+ import {EVDiskDetailedReplicationStatus} from '../../types/api/vdisk';
7
+ import {cn} from '../../utils/cn';
8
+ import {formatPercent} from '../../utils/dataFormatters/dataFormatters';
9
+ import type {PreparedVDisk} from '../../utils/disks/types';
10
+ import {formatDurationToShortTimeFormat} from '../../utils/timeParsers';
11
+ import {parseOptionalNonNegativeNumber} from '../../utils/utils';
12
+ import {DiskStatusLabel} from '../DiskStatus/DiskStatus';
13
+
14
+ import {vDiskStatusKeyset as i18n} from './i18n';
15
+ import {getVDiskReplicationLabel} from './statuses';
16
+
17
+ import './VDiskStatus.scss';
18
+
19
+ const b = cn('ydb-vdisk-status');
20
+
21
+ interface VDiskReplicationStatusProps extends Pick<LabelProps, 'size'> {
22
+ data: Pick<
23
+ PreparedVDisk,
24
+ | 'DetailedReplicationStatus'
25
+ | 'Replicated'
26
+ | 'ReplicationProgress'
27
+ | 'ReplicationSecondsRemaining'
28
+ >;
29
+ }
30
+
31
+ export function VDiskReplicationStatus({data, size}: VDiskReplicationStatusProps) {
32
+ const label = getVDiskReplicationLabel(data);
33
+ const showProgress =
34
+ data.DetailedReplicationStatus === EVDiskDetailedReplicationStatus.InProgress ||
35
+ (!data.DetailedReplicationStatus && data.Replicated === false);
36
+
37
+ return (
38
+ <React.Fragment>
39
+ {label && <DiskStatusLabel {...label} size={size} />}
40
+ {showProgress && <ReplicationProgress data={data} size={size} />}
41
+ </React.Fragment>
42
+ );
43
+ }
44
+
45
+ function ReplicationProgress({data, size}: VDiskReplicationStatusProps) {
46
+ const progress = parseOptionalNonNegativeNumber(data.ReplicationProgress);
47
+ const percentage =
48
+ progress !== undefined && progress <= 1 ? Math.round(progress * 100) : undefined;
49
+ const seconds = parseOptionalNonNegativeNumber(data.ReplicationSecondsRemaining);
50
+ const remaining =
51
+ seconds === undefined
52
+ ? undefined
53
+ : formatDurationToShortTimeFormat(Math.ceil(seconds) * 1000, 2, {compact: true});
54
+ if (percentage === undefined && !remaining) {
55
+ return null;
56
+ }
57
+ return (
58
+ <Flex alignItems="center" gap={2} className={b('replication-progress', {size})}>
59
+ {percentage !== undefined && (
60
+ <React.Fragment>
61
+ <span>{formatPercent(percentage / 100, 0)}</span>
62
+ <div
63
+ role="progressbar"
64
+ aria-label={i18n('label_replication-progress')}
65
+ aria-valuemin={0}
66
+ aria-valuemax={100}
67
+ aria-valuenow={percentage}
68
+ className={b('progress-bar')}
69
+ >
70
+ <Progress value={percentage} theme="info" size="xs" />
71
+ </div>
72
+ </React.Fragment>
73
+ )}
74
+ {remaining && <span>{i18n('context_remaining', {duration: remaining})}</span>}
75
+ </Flex>
76
+ );
77
+ }
@@ -0,0 +1,32 @@
1
+ @use '../../styles/mixins';
2
+
3
+ .ydb-vdisk-status {
4
+ &__replication-progress {
5
+ box-sizing: border-box;
6
+ min-height: 24px;
7
+ padding: 0 10px;
8
+
9
+ color: var(--g-color-text-info-heavy);
10
+ border-radius: var(--g-border-radius-xs);
11
+ background-color: var(--g-color-base-selection);
12
+ @include mixins.text-body-short();
13
+
14
+ &_size_xs {
15
+ min-height: 20px;
16
+ padding: 2px 6px;
17
+ }
18
+
19
+ > span {
20
+ white-space: nowrap;
21
+ }
22
+ }
23
+
24
+ &__progress-bar {
25
+ --g-progress-empty-background-color: var(--g-color-base-info-light);
26
+ --g-progress-filled-background-color: var(--g-color-base-info-heavy);
27
+
28
+ flex-shrink: 0;
29
+
30
+ width: 103px;
31
+ }
32
+ }
@@ -0,0 +1,38 @@
1
+ import type {LabelProps} from '@gravity-ui/uikit';
2
+
3
+ import {EFlag} from '../../types/api/enums';
4
+ import type {EVDiskState} from '../../types/api/vdisk';
5
+ import {VDISK_LABEL_CONFIG} from '../../utils/disks/constants';
6
+ import {calculateFrontQueuesIcon} from '../../utils/disks/iconCalculators';
7
+ import {DiskFlagLabel, DiskStatusLabel} from '../DiskStatus/DiskStatus';
8
+
9
+ import {vDiskStatusKeyset as i18n} from './i18n';
10
+ import {getVDiskStateLabel} from './statuses';
11
+
12
+ export function VDiskStateLabel({state, size}: {state?: EVDiskState} & Pick<LabelProps, 'size'>) {
13
+ return <DiskStatusLabel {...getVDiskStateLabel({VDiskState: state})} size={size} />;
14
+ }
15
+
16
+ export function VDiskDonorLabel({
17
+ donorMode,
18
+ size,
19
+ }: {donorMode?: boolean} & Pick<LabelProps, 'size'>) {
20
+ return donorMode ? (
21
+ <DiskStatusLabel value={i18n('label_donor')} {...VDISK_LABEL_CONFIG.donor} size={size} />
22
+ ) : null;
23
+ }
24
+
25
+ export function VDiskFrontQueuesLabel({flag}: {flag?: EFlag}) {
26
+ return (
27
+ <DiskFlagLabel
28
+ flag={flag}
29
+ icon={calculateFrontQueuesIcon({FrontQueues: flag || EFlag.Grey})}
30
+ />
31
+ );
32
+ }
33
+
34
+ export function VDiskCompactionRankLabel({flag, rank}: {flag?: EFlag; rank: 'fresh' | 'level'}) {
35
+ return (
36
+ <DiskFlagLabel flag={flag} title={i18n(rank === 'fresh' ? 'label_fresh' : 'label_level')} />
37
+ );
38
+ }
@@ -0,0 +1,33 @@
1
+ {
2
+ "label_donor": "Donor",
3
+ "label_fresh": "Fresh Rank",
4
+ "label_level": "Level Rank",
5
+ "label_replicated": "Replicated",
6
+ "label_replication": "Replication",
7
+ "label_replication-progress": "Replication progress",
8
+ "value_ok": "Ok",
9
+ "value_in-progress": "In progress",
10
+ "value_initial": "Initial",
11
+ "value_sync-guid-recovery": "Sync Guid Recovery",
12
+ "value_pdisk-error": "PDisk Error",
13
+ "value_local-recovery-error": "Local Recovery Error",
14
+ "value_sync-guid-recovery-error": "Sync Guid Recovery Error",
15
+ "value_no-data": "No data",
16
+ "value_waiting-for-token": "Waiting for token",
17
+ "value_phantoms-only": "Phantoms only",
18
+ "label_not-replicated": "Not replicated",
19
+ "value_no-detailed-status": "No detailed status",
20
+ "context_state-ok": "The VDisk is operating normally",
21
+ "context_state-initial": "The VDisk is starting",
22
+ "context_state-sync-guid-recovery": "The VDisk is synchronizing with other VDisks of the group",
23
+ "context_state-pdisk-error": "The VDisk cannot operate because its underlying PDisk reported an error",
24
+ "context_state-local-recovery-error": "The VDisk failed to restore its state from the PDisk",
25
+ "context_state-sync-guid-recovery-error": "The VDisk failed to complete synchronization identity with other VDisks in the group",
26
+ "context_state-no-data": "The VDisk state is unknown",
27
+ "context_replicated": "The VDisk is fully replicated",
28
+ "context_not-replicated": "The VDisk isn't replicated",
29
+ "context_replication-in-progress": "Replication is in progress, data is being transferred to VDisk",
30
+ "context_replication-waiting-for-token": "Replication is waiting for a token from the broker",
31
+ "context_replication-phantoms-only": "Replication cannot finish due to phantom blobs",
32
+ "context_remaining": "{{duration}} left"
33
+ }
@@ -0,0 +1,7 @@
1
+ import {registerKeysets} from '../../../utils/i18n';
2
+
3
+ import en from './en.json';
4
+
5
+ const COMPONENT = 'ydb-vdisk-status';
6
+
7
+ export const vDiskStatusKeyset = registerKeysets(COMPONENT, {en});
@@ -0,0 +1,7 @@
1
+ export {
2
+ VDiskCompactionRankLabel,
3
+ VDiskDonorLabel,
4
+ VDiskFrontQueuesLabel,
5
+ VDiskStateLabel,
6
+ } from './VDiskStatus';
7
+ export {VDiskReplicationStatus} from './VDiskReplicationStatus';
@@ -0,0 +1,139 @@
1
+ import {
2
+ ArrowsRotateLeft,
3
+ ArrowsRotateLeftSlash,
4
+ Check,
5
+ CirclePause,
6
+ CircleQuestion,
7
+ CircleStop,
8
+ } from '@gravity-ui/icons';
9
+
10
+ import {EVDiskDetailedReplicationStatus, EVDiskState} from '../../types/api/vdisk';
11
+ import {
12
+ NOT_AVAILABLE_SEVERITY,
13
+ NUMERIC_SEVERITY_TO_LABEL_VIEW,
14
+ VDISK_STATE_SEVERITY_FOR_STATE_MODE,
15
+ } from '../../utils/disks/constants';
16
+ import {calculateStateIcon} from '../../utils/disks/iconCalculators';
17
+ import type {PreparedVDisk} from '../../utils/disks/types';
18
+ import {parseOptionalNonNegativeNumber} from '../../utils/utils';
19
+ import type {DiskStatusLabelData} from '../DiskStatus/DiskStatus';
20
+
21
+ import {vDiskStatusKeyset as i18n} from './i18n';
22
+
23
+ export function getVDiskStateLabel(data: PreparedVDisk): DiskStatusLabelData {
24
+ const state = data.VDiskState;
25
+ const severity = state
26
+ ? (VDISK_STATE_SEVERITY_FOR_STATE_MODE[state] ?? NOT_AVAILABLE_SEVERITY)
27
+ : NOT_AVAILABLE_SEVERITY;
28
+ if (!state || severity === NOT_AVAILABLE_SEVERITY) {
29
+ return {
30
+ value: i18n('value_no-data'),
31
+ theme: 'unknown',
32
+ icon: CircleQuestion,
33
+ tooltip: i18n('context_state-no-data'),
34
+ };
35
+ }
36
+
37
+ const labels: Record<EVDiskState, Pick<DiskStatusLabelData, 'value' | 'tooltip'>> = {
38
+ [EVDiskState.OK]: {
39
+ value: i18n('value_ok'),
40
+ tooltip: i18n('context_state-ok'),
41
+ },
42
+ [EVDiskState.Initial]: {
43
+ value: i18n('value_initial'),
44
+ tooltip: i18n('context_state-initial'),
45
+ },
46
+ [EVDiskState.SyncGuidRecovery]: {
47
+ value: i18n('value_sync-guid-recovery'),
48
+ tooltip: i18n('context_state-sync-guid-recovery'),
49
+ },
50
+ [EVDiskState.PDiskError]: {
51
+ value: i18n('value_pdisk-error'),
52
+ tooltip: i18n('context_state-pdisk-error'),
53
+ },
54
+ [EVDiskState.LocalRecoveryError]: {
55
+ value: i18n('value_local-recovery-error'),
56
+ tooltip: i18n('context_state-local-recovery-error'),
57
+ },
58
+ [EVDiskState.SyncGuidRecoveryError]: {
59
+ value: i18n('value_sync-guid-recovery-error'),
60
+ tooltip: i18n('context_state-sync-guid-recovery-error'),
61
+ },
62
+ };
63
+
64
+ const labelView = NUMERIC_SEVERITY_TO_LABEL_VIEW[severity];
65
+
66
+ return {
67
+ ...labels[state],
68
+ theme: labelView.theme,
69
+ icon: state === EVDiskState.OK ? Check : calculateStateIcon(data),
70
+ dangerHeavy: Boolean(labelView.dangerHeavy),
71
+ };
72
+ }
73
+
74
+ export function getVDiskReplicationLabel(data: PreparedVDisk): DiskStatusLabelData | undefined {
75
+ switch (data.DetailedReplicationStatus) {
76
+ case EVDiskDetailedReplicationStatus.Replicated:
77
+ return replicatedLabel();
78
+ case EVDiskDetailedReplicationStatus.InProgress:
79
+ return {
80
+ title: i18n('label_replication'),
81
+ value: i18n('value_in-progress'),
82
+ theme: 'info',
83
+ icon: ArrowsRotateLeft,
84
+ tooltip: i18n('context_replication-in-progress'),
85
+ };
86
+ case EVDiskDetailedReplicationStatus.WaitingForToken:
87
+ return {
88
+ title: i18n('label_replication'),
89
+ value: i18n('value_waiting-for-token'),
90
+ theme: 'info',
91
+ icon: CirclePause,
92
+ tooltip: i18n('context_replication-waiting-for-token'),
93
+ };
94
+ case EVDiskDetailedReplicationStatus.PhantomsOnly:
95
+ return {
96
+ title: i18n('label_replication'),
97
+ value: i18n('value_phantoms-only'),
98
+ theme: 'info',
99
+ icon: CircleStop,
100
+ tooltip: i18n('context_replication-phantoms-only'),
101
+ };
102
+ default:
103
+ if (data.DetailedReplicationStatus) {
104
+ return undefined;
105
+ }
106
+ if (data.Replicated === true) {
107
+ return replicatedLabel();
108
+ }
109
+ if (data.Replicated === false) {
110
+ const progress = parseOptionalNonNegativeNumber(data.ReplicationProgress);
111
+ const seconds = parseOptionalNonNegativeNumber(data.ReplicationSecondsRemaining);
112
+ if ((progress !== undefined && progress <= 1) || seconds !== undefined) {
113
+ return {
114
+ title: i18n('label_replication'),
115
+ value: i18n('value_no-detailed-status'),
116
+ theme: 'info',
117
+ icon: ArrowsRotateLeft,
118
+ tooltip: i18n('context_not-replicated'),
119
+ };
120
+ }
121
+ return {
122
+ value: i18n('label_not-replicated'),
123
+ theme: 'normal',
124
+ icon: ArrowsRotateLeftSlash,
125
+ tooltip: i18n('context_not-replicated'),
126
+ };
127
+ }
128
+ return undefined;
129
+ }
130
+ }
131
+
132
+ function replicatedLabel(): DiskStatusLabelData {
133
+ return {
134
+ value: i18n('label_replicated'),
135
+ theme: 'success',
136
+ icon: Check,
137
+ tooltip: i18n('context_replicated'),
138
+ };
139
+ }
@@ -5,11 +5,11 @@
5
5
  "field_normalized-occupancy": "Normalized Occupancy",
6
6
  "field_capacity-alert": "Capacity Alert",
7
7
  "value_implicit-unit-count": "1 (implicit)",
8
- "context_pdisk-usage": "Share of PDisk space used by VDisks. System and log reserves are not included.",
9
- "context_vdisk-slot-usage": "Percentage of VDisk space used relative to the first low-space warning. Can exceed 100%.",
10
- "context_vdisk-raw-usage": "Percentage of VDisk space used relative to its fair share on the PDisk. Can exceed 100%.",
8
+ "context_pdisk-usage": "The share of PDisk chunk space used by the residing VDisks. Doesn't include SysLog and CommonLog usage",
9
+ "context_vdisk-slot-usage": "Percentage of used VDisk space relative to the first low-space warning. Can exceed 100%.",
10
+ "context_vdisk-raw-usage": "Percentage of used VDisk space relative to its fair share on the PDisk. Can exceed 100%.",
11
11
  "context_normalized-occupancy": "Internal score used for gently handling low-space cases.",
12
- "context_capacity-alert": "Named status used for gently handling low-space cases.",
12
+ "context_capacity-alert": "The named status used for the graceful low space handling.",
13
13
  "context_group-size-in-units": "Relative capacity of this group (1 = single, 2 = double, …). Affects VDisk space quota on the PDisk.",
14
14
  "context_slot-size-in-units": "Relative size of this PDisk in the cluster (1 = single, 2 = double, …). Same units as Group Size In Units."
15
15
  }
@@ -4,7 +4,7 @@ import {Eye, EyeSlash, Xmark} from '@gravity-ui/icons';
4
4
  import {ActionTooltip, Button, Link as ExternalLink, Icon, TextInput} from '@gravity-ui/uikit';
5
5
  import {useHistory, useLocation, useRouteMatch} from 'react-router-dom';
6
6
 
7
- import routes, {getHomePagePath, parseQuery} from '../../routes';
7
+ import routes, {getClusterPath, getHomePagePath, parseQuery} from '../../routes';
8
8
  import {basename} from '../../store';
9
9
  import {authenticationApi} from '../../store/reducers/authentication/authentication';
10
10
  import {useLoginWithDatabase, useOidcAvailable} from '../../store/reducers/capabilities/hooks';
@@ -12,11 +12,12 @@ import {cn} from '../../utils/cn';
12
12
  import {BRAND_BUTTON_CLASS} from '../../utils/constants';
13
13
  import {prepareCommonErrorMessage} from '../../utils/errors';
14
14
  import {useMetaAuth} from '../../utils/hooks/useMetaAuth';
15
+ import {useTypedSelector} from '../../utils/hooks/useTypedSelector';
15
16
 
16
17
  import i18n from './i18n';
17
18
  import {
18
19
  createSsoAuthorizeUrl,
19
- getSsoReturnTo,
20
+ getAuthReturnTo,
20
21
  isDatabaseError,
21
22
  isPasswordError,
22
23
  isUserError,
@@ -36,6 +37,7 @@ function Authentication({closable = false}: AuthenticationProps) {
36
37
  const history = useHistory();
37
38
  const location = useLocation();
38
39
  const isDirectAuthPage = Boolean(useRouteMatch({path: routes.auth, exact: true}));
40
+ const singleClusterMode = useTypedSelector((state) => state.singleClusterMode);
39
41
 
40
42
  const needDatabase = useLoginWithDatabase();
41
43
  const oidcAvailable = useOidcAvailable();
@@ -45,49 +47,40 @@ function Authentication({closable = false}: AuthenticationProps) {
45
47
  const {returnUrl, database: databaseFromQuery} = parseQuery(location);
46
48
  const currentHref = window.location.href;
47
49
 
48
- const path = React.useMemo(() => {
49
- let path: string | undefined;
50
+ const returnTo = React.useMemo(() => {
51
+ const fallbackPath = singleClusterMode
52
+ ? getClusterPath(undefined, undefined, {withBasename: true})
53
+ : getHomePagePath(undefined, undefined, {withBasename: true});
50
54
 
51
- if (returnUrl) {
52
- const decodedUrl = decodeURIComponent(returnUrl.toString());
53
-
54
- // to prevent page reload we use router history
55
- // history navigates relative to origin
56
- // so we remove origin to make it work properly
57
- const url = new URL(decodedUrl);
58
- let pathname = url.pathname;
59
-
60
- // Remove basename from pathname since history.replace expects paths relative to basename
61
- if (basename && pathname.startsWith(basename)) {
62
- pathname = pathname.slice(basename.length);
63
- }
64
-
65
- // Ensure pathname starts with /
66
- if (pathname && !pathname.startsWith('/')) {
67
- pathname = '/' + pathname;
68
- }
69
-
70
- path = pathname + url.search;
71
- }
72
- return path;
73
- }, [returnUrl]);
55
+ return getAuthReturnTo({
56
+ currentUrl: new URL(currentHref),
57
+ fallbackPath,
58
+ isDirectAuthPage,
59
+ returnUrl,
60
+ });
61
+ }, [currentHref, isDirectAuthPage, returnUrl, singleClusterMode]);
74
62
 
75
- const useMeta = useMetaAuth(path);
63
+ const pathname = new URL(returnTo, currentHref).pathname;
64
+ // Route matching for meta authentication expects a pathname without the router basename.
65
+ const authPath =
66
+ basename && pathname.startsWith(`${basename}/`)
67
+ ? pathname.slice(basename.length)
68
+ : pathname;
69
+ const useMeta = useMetaAuth(authPath);
76
70
 
77
71
  const ssoUrl = React.useMemo(() => {
78
72
  if (!oidcAvailable) {
79
73
  return undefined;
80
74
  }
81
75
 
82
- const homePath = getHomePagePath(undefined, undefined, {withBasename: true});
83
76
  const currentUrl = new URL(currentHref);
84
- const returnTo = getSsoReturnTo({
77
+ const ssoReturnTo = getAuthReturnTo({
85
78
  currentUrl,
86
- fallbackPath: homePath,
79
+ fallbackPath: getHomePagePath(undefined, undefined, {withBasename: true}),
87
80
  isDirectAuthPage,
88
81
  returnUrl,
89
82
  });
90
- return createSsoAuthorizeUrl(currentUrl.host, returnTo);
83
+ return createSsoAuthorizeUrl(currentUrl.host, ssoReturnTo);
91
84
  }, [currentHref, isDirectAuthPage, oidcAvailable, returnUrl]);
92
85
 
93
86
  const [login, setLogin] = React.useState('');
@@ -121,8 +114,10 @@ function Authentication({closable = false}: AuthenticationProps) {
121
114
  authenticate({user: login, password, database, useMeta})
122
115
  .unwrap()
123
116
  .then(() => {
124
- if (path) {
125
- history.replace(path);
117
+ if (isDirectAuthPage) {
118
+ window.location.replace(returnTo);
119
+ } else {
120
+ window.location.reload();
126
121
  }
127
122
  })
128
123
  .catch((error) => {
@@ -11,7 +11,7 @@ export function createSsoAuthorizeUrl(host: string, returnTo: string) {
11
11
  return url.href;
12
12
  }
13
13
 
14
- interface GetSsoReturnToParams {
14
+ interface GetAuthReturnToParams {
15
15
  currentUrl: URL;
16
16
  fallbackPath: string;
17
17
  isDirectAuthPage: boolean;
@@ -28,12 +28,12 @@ function isSafeLocalReturnTo(path: string) {
28
28
  );
29
29
  }
30
30
 
31
- export function getSsoReturnTo({
31
+ export function getAuthReturnTo({
32
32
  currentUrl,
33
33
  fallbackPath,
34
34
  isDirectAuthPage,
35
35
  returnUrl,
36
- }: GetSsoReturnToParams) {
36
+ }: GetAuthReturnToParams) {
37
37
  if (!isDirectAuthPage) {
38
38
  const path = `${currentUrl.pathname}${currentUrl.search}${currentUrl.hash}`;
39
39
  return isSafeLocalReturnTo(path) ? path : fallbackPath;
@@ -9,6 +9,7 @@ import {
9
9
  import {useTypedSelector} from '../../utils/hooks';
10
10
  import {Healthcheck} from '../Tenant/Healthcheck/Healthcheck';
11
11
  import {HealthcheckDrawer} from '../Tenant/Healthcheck/components/HealthcheckDrawer';
12
+ import {getDatabaseHealthcheckAssistantTarget} from '../Tenant/Healthcheck/utils';
12
13
 
13
14
  import i18n from './i18n';
14
15
 
@@ -184,6 +185,11 @@ export function ClusterDrawerHealthcheck({
184
185
 
185
186
  return (
186
187
  <HealthcheckDrawer
188
+ target={getDatabaseHealthcheckAssistantTarget({
189
+ database,
190
+ clusterName,
191
+ scope: 'cluster',
192
+ })}
187
193
  isDrawerVisible={Boolean(showHealthcheck) && Boolean(database)}
188
194
  onCloseDrawer={handleCloseDrawer}
189
195
  onTransitionInComplete={
@@ -48,6 +48,7 @@ export function ClusterDrawerHealthcheck({
48
48
 
49
49
  return (
50
50
  <HealthcheckDrawer
51
+ target={clusterName ? {scope: 'cluster', request: {clusterName}} : undefined}
51
52
  isDrawerVisible={isVisible && Boolean(clusterName)}
52
53
  onCloseDrawer={handleCloseDrawer}
53
54
  renderDrawerContent={renderDrawerContent}
@@ -1,6 +1,7 @@
1
1
  import {HeaderBreadcrumbs} from './HeaderBreadcrumbs';
2
2
  import {HeaderLeftControls} from './HeaderLeftControls';
3
3
  import {HeaderRightControls} from './HeaderRightControls';
4
+ import {StorageGroupLeftControls} from './StorageGroupLeftControls';
4
5
  import {b} from './constants';
5
6
  import {useHeaderBreadcrumbs} from './hooks/useHeaderBreadcrumbs';
6
7
  import {useHeaderData} from './hooks/useHeaderData';
@@ -66,18 +67,25 @@ export function Header() {
66
67
  return null;
67
68
  }
68
69
 
69
- const leftControls =
70
- database && isDatabasePage && isV2NavigationEnabled ? (
70
+ const renderLeftControls = () => {
71
+ if (page === 'storageGroup') {
72
+ return <StorageGroupLeftControls />;
73
+ }
74
+ return database && isDatabasePage && isV2NavigationEnabled ? (
71
75
  <HeaderLeftControls
72
76
  database={database}
73
77
  databaseData={databaseData}
74
78
  isDatabaseDataLoading={isDatabaseDataLoading}
75
79
  />
76
80
  ) : null;
81
+ };
77
82
 
78
83
  return (
79
84
  <header className={b()}>
80
- <HeaderBreadcrumbs breadcrumbItems={breadcrumbItems} endContent={leftControls} />
85
+ <HeaderBreadcrumbs
86
+ breadcrumbItems={breadcrumbItems}
87
+ endContent={renderLeftControls()}
88
+ />
81
89
 
82
90
  <HeaderRightControls
83
91
  clusterName={clusterName}
@@ -0,0 +1,38 @@
1
+ import {ClipboardButton, Flex} from '@gravity-ui/uikit';
2
+ import {skipToken} from '@reduxjs/toolkit/query';
3
+ import {StringParam, useQueryParams} from 'use-query-params';
4
+
5
+ import {storageApi} from '../../store/reducers/storage/storage';
6
+ import {valueIsDefined} from '../../utils';
7
+ import {useDatabaseFromQuery} from '../../utils/hooks/useDatabaseFromQuery';
8
+ import {StorageGroupStateLabel} from '../Storage/StorageGroupStateLabel';
9
+
10
+ import {b} from './constants';
11
+ import {headerKeyset} from './i18n';
12
+
13
+ export function StorageGroupLeftControls() {
14
+ const [{groupId}] = useQueryParams({groupId: StringParam});
15
+ const database = useDatabaseFromQuery();
16
+ const {currentData} = storageApi.endpoints.getStorageGroupsInfo.useQueryState(
17
+ valueIsDefined(groupId)
18
+ ? {groupId, with: 'all', fieldsRequired: 'all', database}
19
+ : skipToken,
20
+ );
21
+
22
+ if (!groupId) {
23
+ return null;
24
+ }
25
+
26
+ return (
27
+ <Flex alignItems="center" gap={2} className={b('left-controls')}>
28
+ <ClipboardButton
29
+ text={groupId}
30
+ view="flat-secondary"
31
+ size="s"
32
+ aria-label={headerKeyset('action_copy-group-id-from-breadcrumb')}
33
+ tooltipInitialText={headerKeyset('action_copy-group-id')}
34
+ />
35
+ <StorageGroupStateLabel state={currentData?.groups?.[0]?.State} size="xs" />
36
+ </Flex>
37
+ );
38
+ }
@@ -24,5 +24,7 @@
24
24
  "description_connect-to-db": "Connect to database",
25
25
 
26
26
  "title_monitoring": "Open in {{system}}",
27
- "action_copy-path": "Copy path"
27
+ "action_copy-path": "Copy path",
28
+ "action_copy-group-id": "Copy Storage Group ID",
29
+ "action_copy-group-id-from-breadcrumb": "Copy Storage Group ID from breadcrumb"
28
30
  }