Skip to content

Unify values for millis properties #672

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

Closed
wants to merge 2 commits into from
Closed

Unify values for millis properties #672

wants to merge 2 commits into from

Conversation

sbuliarca
Copy link
Contributor

Setting the values based on the common ones. See pr: utilitywarehouse/tflint-ruleset-kafka-config#31

@sbuliarca sbuliarca requested a review from a team as a code owner November 4, 2024 09:16
@uw-infra
Copy link

uw-infra commented Nov 4, 2024

Terraform run output for

Cluster: prod-aws
Module: pubsub/kafka-shared-msk-payment-platform
Path: prod-aws/kafka-shared-msk/payment-platform
Commit ID: 8a6d2b0ce5e0c50b8c32dd40df04614beb97dcab
✅ Run Status: Ok, Run Summary: Plan: 0 to add, 15 to change, 0 to destroy.
Terraform used the selected providers to generate the following execution
plan. Resource actions are indicated with the following symbols:
  ~ update in-place

Terraform will perform the following actions:

  # kafka_topic.notifications_stripe_raw will be updated in-place
  ~ resource "kafka_topic" "notifications_stripe_raw" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.notifications.stripe.raw"
        name               = "payment-platform.notifications.stripe.raw"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.notifications_tx will be updated in-place
  ~ resource "kafka_topic" "notifications_tx" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.notifications.tx"
        name               = "payment-platform.notifications.tx"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.notifications_worldpay_raw will be updated in-place
  ~ resource "kafka_topic" "notifications_worldpay_raw" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.notifications.worldpay.raw"
        name               = "payment-platform.notifications.worldpay.raw"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.openbanking_deadletter_v1_internal_payment_methods will be updated in-place
  ~ resource "kafka_topic" "openbanking_deadletter_v1_internal_payment_methods" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.openbanking-deadletter.v1.internal.payment-methods"
        name               = "payment-platform.openbanking-deadletter.v1.internal.payment-methods"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.openbanking_deadletter_v1_internal_payments will be updated in-place
  ~ resource "kafka_topic" "openbanking_deadletter_v1_internal_payments" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.openbanking-deadletter.v1.internal.payments"
        name               = "payment-platform.openbanking-deadletter.v1.internal.payments"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.openbanking_v1_internal_payment_methods will be updated in-place
  ~ resource "kafka_topic" "openbanking_v1_internal_payment_methods" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.openbanking.v1.internal.payment-methods"
        name               = "payment-platform.openbanking.v1.internal.payment-methods"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.openbanking_v1_internal_payments will be updated in-place
  ~ resource "kafka_topic" "openbanking_v1_internal_payments" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.openbanking.v1.internal.payments"
        name               = "payment-platform.openbanking.v1.internal.payments"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_analysis_payment_method will be updated in-place
  ~ resource "kafka_topic" "payment_analysis_payment_method" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment-analysis.payment-method"
        name               = "payment-platform.payment-analysis.payment-method"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_data_staged will be updated in-place
  ~ resource "kafka_topic" "payment_data_staged" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.data-staged"
        name               = "payment-platform.payment.data-staged"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_enriched_txs will be updated in-place
  ~ resource "kafka_topic" "payment_enriched_txs" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.enriched-txs"
        name               = "payment-platform.payment.enriched-txs"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_gateway_reconciliation will be updated in-place
  ~ resource "kafka_topic" "payment_gateway_reconciliation" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.gateway.reconciliation"
        name               = "payment-platform.payment.gateway.reconciliation"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_gateway_reconciliation_status_changed will be updated in-place
  ~ resource "kafka_topic" "payment_gateway_reconciliation_status_changed" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.gateway.reconciliation.status-changed"
        name               = "payment-platform.payment.gateway.reconciliation.status-changed"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_method_linked will be updated in-place
  ~ resource "kafka_topic" "payment_method_linked" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.method-linked"
        name               = "payment-platform.payment.method-linked"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_method_verified will be updated in-place
  ~ resource "kafka_topic" "payment_method_verified" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.method-verified"
        name               = "payment-platform.payment.method-verified"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_payment will be updated in-place
  ~ resource "kafka_topic" "payment_payment" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.payment"
        name               = "payment-platform.payment.payment"
        # (2 unchanged attributes hidden)
    }

Plan: 0 to add, 15 to change, 0 to destroy.

To manually trigger plan again please post @terraform-applier plan prod-aws/kafka-shared-msk/payment-platform as comment.

@uw-infra
Copy link

uw-infra commented Nov 4, 2024

Terraform run output for

Cluster: dev-aws
Module: pubsub/kafka-shared-msk-payment-platform
Path: dev-aws/kafka-shared-msk/payment-platform
Commit ID: 8a6d2b0ce5e0c50b8c32dd40df04614beb97dcab
✅ Run Status: Ok, Run Summary: Plan: 0 to add, 7 to change, 0 to destroy.
Terraform used the selected providers to generate the following execution
plan. Resource actions are indicated with the following symbols:
  ~ update in-place

Terraform will perform the following actions:

  # kafka_topic.payment_analysis_payment_method will be updated in-place
  ~ resource "kafka_topic" "payment_analysis_payment_method" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment-analysis.payment-method"
        name               = "payment-platform.payment-analysis.payment-method"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_gateway_reconciliation will be updated in-place
  ~ resource "kafka_topic" "payment_gateway_reconciliation" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.gateway.reconciliation"
        name               = "payment-platform.payment.gateway.reconciliation"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_gateway_reconciliation_status_changed will be updated in-place
  ~ resource "kafka_topic" "payment_gateway_reconciliation_status_changed" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.gateway.reconciliation.status-changed"
        name               = "payment-platform.payment.gateway.reconciliation.status-changed"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_method_created will be updated in-place
  ~ resource "kafka_topic" "payment_method_created" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.method-created"
        name               = "payment-platform.payment.method-created"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_method_linked will be updated in-place
  ~ resource "kafka_topic" "payment_method_linked" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.method-linked"
        name               = "payment-platform.payment.method-linked"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_method_verified will be updated in-place
  ~ resource "kafka_topic" "payment_method_verified" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "63113904000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.method-verified"
        name               = "payment-platform.payment.method-verified"
        # (2 unchanged attributes hidden)
    }

  # kafka_topic.payment_payment will be updated in-place
  ~ resource "kafka_topic" "payment_payment" {
      ~ config             = {
          ~ "retention.ms"          = "31557600000" -> "31556952000"
            # (5 unchanged elements hidden)
        }
        id                 = "payment-platform.payment.payment"
        name               = "payment-platform.payment.payment"
        # (2 unchanged attributes hidden)
    }

Plan: 0 to add, 7 to change, 0 to destroy.

To manually trigger plan again please post @terraform-applier plan dev-aws/kafka-shared-msk/payment-platform as comment.

@sbuliarca sbuliarca requested review from a team as code owners November 4, 2024 09:17
@uw-infra
Copy link

uw-infra commented Nov 4, 2024

A limit of 5 modules per PR has been reached, hence auto plan is disabled for this PR.
Please post @terraform-applier plan <module_name> as comment if you want to request terraform plan for a particular module.

@sbuliarca sbuliarca marked this pull request as draft November 4, 2024 09:19
@sbuliarca sbuliarca closed this Nov 4, 2024
@@ -12,7 +12,7 @@ resource "kafka_topic" "transactions_auditor_diff_events" {
"remote.storage.enable" = "true"
# keep data in primary storage for 2 days
"local.retention.ms" = "172800000"
# keep data for 2 months
# keep data for 1.9712525667351128 months
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe it would be worth to round it up a little bit?
It makes no practical difference for users, I think

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yea, that would be an option indeed. Let me try and see if I manage something with floats

@sbuliarca sbuliarca deleted the millis-fixes2 branch November 4, 2024 10:42
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.

3 participants