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

WIP - Clickhouse integration #507

Draft
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

Arun-kc
Copy link
Contributor

@Arun-kc Arun-kc commented Aug 27, 2023

@ogirardot
Copy link

Hello, do you need any help, I'd be happy to contribute

@Arun-kc
Copy link
Contributor Author

Arun-kc commented Sep 27, 2023

Hello, do you need any help, I'd be happy to contribute

Hey, would love to receive any help that you could provide! Please check out this guideline provided by Maayan.

As of now, we have completed step 1. Now we need to focus on adding support in the CLI for Slack alerts and UI generation

Copy link
Contributor

@ofek1weiss ofek1weiss left a comment

Choose a reason for hiding this comment

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

Great contribution @Arun-kc
I see its still a WIP, but i still added some notes (mainly conventions), so take a look when you got the time 😄

{% endmacro %}

{% macro clickhouse__edr_current_timestamp_in_utc() %}
toDateTime(toUInt32(toUnixTimestamp(now()) - 7 * 86400))
Copy link
Contributor

Choose a reason for hiding this comment

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

Can you explain a bit about these numbers? how does it make it into UTC?

_parameter("user", target.user),
_parameter("password", "<PASSWORD>"),
_parameter("schema", elementary_schema),
_parameter("driver", "<http|native>"),
Copy link
Contributor

Choose a reason for hiding this comment

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

is this available through the target (e.g target.driver)? if so i believe it would be better

@@ -27,7 +27,11 @@ time_window_aggregation as (
bucket_duration_hours,
updated_at,
avg(metric_value) over (partition by metric_name, full_table_name, column_name order by bucket_start asc rows between unbounded preceding and current row) as training_avg,
{% if target.type == 'clickhouse' %}
Copy link
Contributor

Choose a reason for hiding this comment

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

We prefer to have the adapter specific code use adapter.dispatch and contained in the cross_db_utils section of the code, if you could add there an edr_stddev macro it would be awesome

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

Successfully merging this pull request may close these issues.

None yet

3 participants