fix: materialized view
This commit is contained in:
@ -104,6 +104,8 @@ SETTINGS index_granularity = 8192;
|
|||||||
-- -----------------------------------------------------------------------------
|
-- -----------------------------------------------------------------------------
|
||||||
-- Vue matérialisée : parse le JSON de http_logs_raw vers http_logs
|
-- Vue matérialisée : parse le JSON de http_logs_raw vers http_logs
|
||||||
-- -----------------------------------------------------------------------------
|
-- -----------------------------------------------------------------------------
|
||||||
|
DROP TABLE IF EXISTS mabase_prod.mv_http_logs;
|
||||||
|
|
||||||
CREATE MATERIALIZED VIEW IF NOT EXISTS mabase_prod.mv_http_logs
|
CREATE MATERIALIZED VIEW IF NOT EXISTS mabase_prod.mv_http_logs
|
||||||
TO mabase_prod.http_logs
|
TO mabase_prod.http_logs
|
||||||
AS SELECT
|
AS SELECT
|
||||||
@ -140,10 +142,12 @@ AS SELECT
|
|||||||
coalesce(JSONExtractString(raw_json, 'ja3'), '') AS ja3,
|
coalesce(JSONExtractString(raw_json, 'ja3'), '') AS ja3,
|
||||||
coalesce(JSONExtractString(raw_json, 'ja3_hash'), '') AS ja3_hash,
|
coalesce(JSONExtractString(raw_json, 'ja3_hash'), '') AS ja3_hash,
|
||||||
coalesce(JSONExtractString(raw_json, 'ja4'), '') AS ja4,
|
coalesce(JSONExtractString(raw_json, 'ja4'), '') AS ja4,
|
||||||
|
coalesce(JSONExtractString(raw_json, 'client_headers'), '') AS client_headers,
|
||||||
coalesce(JSONExtractString(raw_json, 'header_User-Agent'), '') AS header_user_agent,
|
coalesce(JSONExtractString(raw_json, 'header_User-Agent'), '') AS header_user_agent,
|
||||||
coalesce(JSONExtractString(raw_json, 'header_Accept'), '') AS header_accept,
|
coalesce(JSONExtractString(raw_json, 'header_Accept'), '') AS header_accept,
|
||||||
coalesce(JSONExtractString(raw_json, 'header_Accept-Encoding'), '') AS header_accept_encoding,
|
coalesce(JSONExtractString(raw_json, 'header_Accept-Encoding'), '') AS header_accept_encoding,
|
||||||
coalesce(JSONExtractString(raw_json, 'header_Accept-Language'), '') AS header_accept_language,
|
coalesce(JSONExtractString(raw_json, 'header_Accept-Language'), '') AS header_accept_language,
|
||||||
|
coalesce(JSONExtractString(raw_json, 'header_Content-Type'), '') AS header_content_type,
|
||||||
coalesce(JSONExtractString(raw_json, 'header_X-Request-Id'), '') AS header_x_request_id,
|
coalesce(JSONExtractString(raw_json, 'header_X-Request-Id'), '') AS header_x_request_id,
|
||||||
coalesce(JSONExtractString(raw_json, 'header_X-Trace-Id'), '') AS header_x_trace_id,
|
coalesce(JSONExtractString(raw_json, 'header_X-Trace-Id'), '') AS header_x_trace_id,
|
||||||
coalesce(JSONExtractString(raw_json, 'header_X-Forwarded-For'), '') AS header_x_forwarded_for,
|
coalesce(JSONExtractString(raw_json, 'header_X-Forwarded-For'), '') AS header_x_forwarded_for,
|
||||||
|
|||||||
Reference in New Issue
Block a user