ydb-platform / ydb-embedded-ui

MIT License
27 stars 6 forks source link

Update in-store column tables stats request #908

Closed artemmufazalov closed 1 month ago

artemmufazalov commented 2 months ago

Currently we request data with query like SELECT * FROM column_table/.sys/primary_index_stats.

It's not an effective way to gather stats, since table could have a lot of rows.

  1. We need to optimize request, so it will be like SELECT SUM(Rows) AS Rows, SUM(Bytes) AS BytesCompressed, SUM(RawBytes) AS BytesUncompressed from column_table/.sys/primary_index_stats
  2. We need to discuss, whether this way of gathering stats is really needed

https://github.com/ydb-platform/ydb-embedded-ui/blob/main/src/store/reducers/olapStats.ts

adameat commented 1 month ago

@zverevgeny could you please tell us wherever we need to collect this stats or not? and if we do, what will be the correct query for that?