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

feat(uptime): storage configuration and and consumer #6697

Draft
wants to merge 20 commits into
base: jferg/uptime-checks-1
Choose a base branch
from

Conversation

JoshFerge
Copy link
Member

No description provided.

Copy link

github-actions bot commented Dec 20, 2024

This PR has a migration; here is the generated SQL for ./snuba/migrations/groups.py ()

-- start migrations

-- forward migration events_analytics_platform : 0019_add_project_id_index_back
Local op: ALTER TABLE eap_spans_2_local ADD INDEX IF NOT EXISTS bf_project_id project_id TYPE bloom_filter GRANULARITY 1;
-- end forward migration events_analytics_platform : 0019_add_project_id_index_back




-- backward migration events_analytics_platform : 0019_add_project_id_index_back
Local op: ALTER TABLE eap_spans_2_local DROP INDEX IF EXISTS bf_project_id;
-- end backward migration events_analytics_platform : 0019_add_project_id_index_back
-- forward migration events_analytics_platform : 0020_uptime_monitors_init
Local op: CREATE TABLE IF NOT EXISTS uptime_monitor_checks_local (organization_id UInt64, project_id UInt64, environment LowCardinality(Nullable(String)), uptime_subscription_id UUID, uptime_check_id UUID, scheduled_check_time DateTime64(3), timestamp DateTime64(3), duration_ms UInt64, region_slug LowCardinality(String), check_status LowCardinality(String), check_status_reason LowCardinality(String), http_status_code UInt16, trace_id UUID, retention_days UInt16) ENGINE ReplicatedReplacingMergeTree('/clickhouse/tables/events_analytics_platform/{shard}/default/uptime_monitor_checks_local', '{replica}') ORDER BY (organization_id, project_id, toDateTime(timestamp), trace_id, uptime_check_id) PARTITION BY (retention_days, toMonday(timestamp)) TTL toDateTime(timestamp) + toIntervalDay(retention_days) SETTINGS index_granularity=8192;
Distributed op: CREATE TABLE IF NOT EXISTS uptime_monitor_checks_dist (organization_id UInt64, project_id UInt64, environment LowCardinality(Nullable(String)), uptime_subscription_id UUID, uptime_check_id UUID, scheduled_check_time DateTime64(3), timestamp DateTime64(3), duration_ms UInt64, region_slug LowCardinality(String), check_status LowCardinality(String), check_status_reason LowCardinality(String), http_status_code UInt16, trace_id UUID, retention_days UInt16) ENGINE Distributed(`cluster_one_sh`, default, uptime_monitor_checks_local, cityHash64(reinterpretAsUInt128(trace_id)));
-- end forward migration events_analytics_platform : 0020_uptime_monitors_init




-- backward migration events_analytics_platform : 0020_uptime_monitors_init
Distributed op: DROP TABLE IF EXISTS uptime_monitor_checks_dist;
Local op: DROP TABLE IF EXISTS uptime_monitor_checks_local;
-- end backward migration events_analytics_platform : 0020_uptime_monitors_init

Copy link

codecov bot commented Dec 20, 2024

❌ 1 Tests Failed:

Tests completed Failed Passed Skipped
2638 1 2637 5
View the top 1 failed tests by shortest run time
tests.utils.streams.test_topics::test_valid_topics
Stack Traces | 0.125s run time
Traceback (most recent call last):
  File ".../local/lib/python3.11....../site-packages/sentry_kafka_schemas/sentry_kafka_schemas.py", line 80, in get_topic
    with open(topic_path) as f:
         ^^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: '.../local/lib/python3.11.../sentry_kafka_schemas/topics/snuba-dead-letter-uptime-monitor-checks.yaml'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File ".../utils/streams/test_topics.py", line 10, in test_valid_topics
    sentry_kafka_schemas.get_topic(
  File ".../local/lib/python3.11....../site-packages/sentry_kafka_schemas/sentry_kafka_schemas.py", line 83, in get_topic
    raise SchemaNotFound
sentry_kafka_schemas.sentry_kafka_schemas.SchemaNotFound

To view more test analytics, go to the Test Analytics Dashboard
📢 Thoughts on this report? Let us know!

@JoshFerge
Copy link
Member Author

depends on getsentry/sentry-kafka-schemas#359 being merged and us bumping the kafka schema

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant