diff --git a/dev-aws/kafka-shared-msk/account-identity/account.tf b/dev-aws/kafka-shared-msk/account-identity/account.tf index 2673b200..27b5ac1b 100644 --- a/dev-aws/kafka-shared-msk/account-identity/account.tf +++ b/dev-aws/kafka-shared-msk/account-identity/account.tf @@ -132,6 +132,22 @@ resource "kafka_topic" "account_identity_account_bill_writes_public" { replication_factor = 3 } +resource "kafka_topic" "account_identity_account_history_v1" { + config = { + "cleanup.policy" = "delete" + "compression.type" = "zstd" + # keep data forever + "retention.ms" = "-1" + # enable remote storage + "remote.storage.enable" = "true" + # keep data in primary storage for 1 day + "local.retention.ms" = "86400000" + } + name = "account-identity.account.history.v1" + partitions = 15 + replication_factor = 3 +} + moved { from = kafka_topic.account_identity_accunt_bill_writes_public to = kafka_topic.account_identity_account_bill_writes_public @@ -186,6 +202,14 @@ module "account_identity_account_api_change_notifier" { cert_common_name = "account-platform/account_api_change_notifier" } +module "account_identity_account_api_history" { + source = "../../../modules/tls-app" + consume_topics = [kafka_topic.account_identity_account_atomic_v1.name] + consume_groups = ["account-identity.account-api-history"] + produce_topics = [kafka_topic.account_identity_account_history_v1.name] + cert_common_name = "account-platform/account_api_history" +} + module "account_identity_account_v2_to_legacy" { source = "../../../modules/tls-app" consume_topics = [kafka_topic.account_identity_account_events_v2.name]