Skip to content
This repository was archived by the owner on Apr 2, 2024. It is now read-only.

Conversation

arajkumar
Copy link
Member

@arajkumar arajkumar commented Jul 15, 2022

Description

Problem statment

PromscaleCompressionLow alert fires regardless of a good compression ratio.

Root cause

SQL query which populates promscale_sql_database_chunks_count is a sum of the below metrics,

  1. Uncompressed Chunks
  2. Proxy Chunks which points to Compressed Chunks
  3. Compressed Chunks

However the total chunk count should be just (1) + (3), because (2) is already pointing to (3) and which leads to double counting.

Solution

Fix the SQL query to consider entries which has compressed_chunk_id as null and this will be true for both (1) and (3).

Signed-off-by: Arunprasad Rajkumar [email protected]

Merge requirements

Please take into account the following non-code changes that you may need to make with your PR:

  • CHANGELOG entry for user-facing changes
  • Updated the relevant documentation

@arajkumar arajkumar force-pushed the remove-PromscaleCacheTooSmall-alert branch from f404d46 to 9a93512 Compare July 15, 2022 06:28
@arajkumar arajkumar marked this pull request as ready for review July 15, 2022 06:28
@arajkumar arajkumar requested a review from a team as a code owner July 15, 2022 06:28
@arajkumar arajkumar force-pushed the remove-PromscaleCacheTooSmall-alert branch 2 times, most recently from d3df82c to ff5de89 Compare July 15, 2022 07:12
@arajkumar arajkumar self-assigned this Jul 15, 2022
…unt metric

Problem statment:
`PromscaleCompressionLow` alert fires regardless of a good compression ratio.

Root cause:
SQL query which populates `promscale_sql_database_chunks_count` is a sum of the below metrics,
1) Uncompressed Chunks
2) Proxy Chunks which points to Compressed Chunks
3) Compressed Chunks

However the total chunk count should be just (1) + (3), because (2) is already pointing to (3) and which leads to double counting.

Solution:
Fix the SQL query to consider entries which has `compressed_chunk_id` as null and this will be true for both (1) and (3).

Signed-off-by: Arunprasad Rajkumar <[email protected]>
@arajkumar arajkumar force-pushed the remove-PromscaleCacheTooSmall-alert branch from ff5de89 to 3a14dd3 Compare July 15, 2022 10:35
Copy link
Member

@JamesGuthrie JamesGuthrie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minor nit

@arajkumar arajkumar requested a review from JamesGuthrie July 15, 2022 12:42
@arajkumar arajkumar merged commit 107ba0f into timescale:master Jul 18, 2022
@arajkumar arajkumar deleted the remove-PromscaleCacheTooSmall-alert branch July 18, 2022 10:44
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants