Skip to content

Open source, composable payments platform | PCI compliant | SaaS and Self-host options | Enables connectivity to multiple payment, payout, fraud, vault and tokenization providers | Uplifts authorization with intelligent routing and revenue recovery | Reduce payment processing costs with cost observability | Reduces payment ops with reconciliation

fix(events): Correct parsing of API events with user event_type for Clickhouse (#5022)

Abhishek Kanojia2106a27f4059
diff --git a/crates/api_models/src/events/user.rs b/crates/api_models/src/events/user.rs
index c41f52a93e..287bafaace 100644
--- a/crates/api_models/src/events/user.rs
+++ b/crates/api_models/src/events/user.rs
@@ -24,7 +24,6 @@ use crate::user::{
impl ApiEventMetric for DashboardEntryResponse {
fn get_api_event_type(&self) -> Option<ApiEventsType> {
Some(ApiEventsType::User {
- merchant_id: self.merchant_id.clone(),
user_id: self.user_id.clone(),
})
}
@@ -34,7 +33,6 @@ impl ApiEventMetric for DashboardEntryResponse {
impl ApiEventMetric for VerifyTokenResponse {
fn get_api_event_type(&self) -> Option<ApiEventsType> {
Some(ApiEventsType::User {
- merchant_id: self.merchant_id.clone(),
user_id: self.user_email.peek().to_string(),
})
}
diff --git a/crates/common_utils/src/events.rs b/crates/common_utils/src/events.rs
index 1052840dbc..ef5502d8b5 100644
--- a/crates/common_utils/src/events.rs
+++ b/crates/common_utils/src/events.rs
@@ -29,8 +29,6 @@ pub enum ApiEventsType {
customer_id: id_type::CustomerId,
},
User {
- //specified merchant_id will overridden on global defined
- merchant_id: String,
user_id: String,
},
PaymentMethodList {
diff --git a/docker-compose.yml b/docker-compose.yml
index d16f946a6e..57f7ccde1c 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -378,6 +378,8 @@ services:
- "8123:8123"
volumes:
- ./crates/analytics/docs/clickhouse/scripts:/docker-entrypoint-initdb.d
+ environment:
+ - TZ=Asia/Kolkata
profiles:
- olap
ulimits: