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

google_integration_connectors_connection log_config bug #20642

Open
ramguru-sagent opened this issue Dec 10, 2024 · 0 comments
Open

google_integration_connectors_connection log_config bug #20642

ramguru-sagent opened this issue Dec 10, 2024 · 0 comments
Labels

Comments

@ramguru-sagent
Copy link

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request.
  • Please do not leave +1 or me too comments, they generate extra noise for issue followers and do not help prioritize the request.
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment.
  • If an issue is assigned to a user, that user is claiming responsibility for the issue.
  • Customers working with a Google Technical Account Manager or Customer Engineer can ask them to reach out internally to expedite investigation and resolution of this issue.

Terraform Version & Provider Version(s)

Terraform v1.9.7
on darwin_arm64

  • provider registry.terraform.io/hashicorp/google v6.12.0

Affected Resource(s)

google_integration_connectors_connection

Terraform Configuration

resource "google_integration_connectors_connection" "sftp_connector" {
  name              = join("-", [var.resource_prefix, var.connector_name])
  location          = var.location
  connector_version = var.connector_version
  description       = "SFTP connector for ${var.environment} environment"
  project           = var.project
  service_account   = var.service_account_email

  node_config {
    max_node_count = var.node_config.max_node_count
    min_node_count = var.node_config.min_node_count
  }

  config_variable {
    boolean_value = false
    integer_value = 0
    key           = "remote_path"
    string_value  = var.sftp_remote_path
  }

  auth_config {
    auth_type = "USER_PASSWORD"
    user_password {
      username = var.sftp_username
      password {
        secret_version = var.secret_version_name
      }
    }
  }

  destination_config {
    key = "remote_host"
    destination {
      host = var.sftp_hostname
      port = var.sftp_port
    }
  }

  labels = merge(var.additional_labels, var.common_labels)

  lifecycle {
    ignore_changes = [
      auth_config[0].user_password[0].password[0].secret_version
    ]
  }

  log_config {
    enabled = var.log_enabled
  }
}

Debug Output

 # module.config.google_integration_connectors_connection.sftp_connector will be updated in-place
  ~ resource "google_integration_connectors_connection" "sftp_connector" {
        id                             = "xxxxxxx"
        name                           = "xxxxxxx"
        # (19 unchanged attributes hidden)

      + log_config {
          + enabled = false
        }

        # (4 unchanged blocks hidden)

Expected Behavior

setting log_config to false removes the config block in statefile. Because of this, every time i apply the changes, its trying to get log_config to false.

Actual Behavior

The statefile should retain the log configuration state when enable = false, which occurs with the SFTP connector but not with the GCS connector.

Steps to reproduce

Create a sftp connector with the above referenced code

Important Factoids

No response

References

No response

@github-actions github-actions bot added forward/review In review; remove label to forward service/integrationconnectors labels Dec 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant