Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UI: Showing Block Size Stats #7233

Merged

Commits on Mar 25, 2024

  1. feat(ui): added BlockSizeStats calculation to blocks page

    A block can have a list of contained files set in `.thanos.files`.
    If the `files` array is set, all referenced files with `size_bytes` set are counted:
    - sum of all `chunk/*` file sizes
    - size of index file
    - total size (sum of both)
    
    Shows statistics about the selected block in the block details view:
    - Total size of block
    - Size of index (and percentage of total)
    - Size of all chunks (and percentage of total)
    - Daily growth, based on total size and block duration
    
    Output is humanized up to Pebibytes and fixed to two decimal places;
    raw bytes are accessible through mouse over / title text.
    
    Signed-off-by: Markus Möslinger <markus.moeslinger@socra.dev>
    outofrange committed Mar 25, 2024
    Configuration menu
    Copy the full SHA
    8f44102 View commit details
    Browse the repository at this point in the history
  2. feat(ui): added aggregated BlockSizeStats to blocks row title

    Added total size of all blocks from a source to the row title, beneath the source name.
    
    The shown total size is humanized up to pebibytes and fixed to two decimal places;
    raw bytes value is accessible through mouse over / title text.
    
    The shown value will refresh with selected compaction levels, but doesn't take block filter into account.
    
    I thought about showing daily growth as well, but just summing all milliseconds of all blocks doesn't work with overlapping blocks / multiple resolutions.
    
    Signed-off-by: Markus Möslinger <markus.moeslinger@socra.dev>
    outofrange committed Mar 25, 2024
    Configuration menu
    Copy the full SHA
    1077574 View commit details
    Browse the repository at this point in the history
  3. chore(docs): added UI block size PR to CHANGELOG.md

    Signed-off-by: Markus Möslinger <markus.moeslinger@socra.dev>
    outofrange committed Mar 25, 2024
    Configuration menu
    Copy the full SHA
    ce31f00 View commit details
    Browse the repository at this point in the history
  4. chore(ui): removed comments

    Automatic code formatting duplicated some comments near import statements.
    
    Signed-off-by: Markus Möslinger <markus.moeslinger@socra.dev>
    outofrange committed Mar 25, 2024
    Configuration menu
    Copy the full SHA
    ca7ed42 View commit details
    Browse the repository at this point in the history