title: Change eventbridge cron rule name in terraform
body: <p>I have a lambda that I trigger with an <code>EventBridge</code>.</p>
  <p>I have <code>allowed_triggers</code> in my <code>lambda_function</code>:</p>
  <pre><code>  allowed_triggers = {
      &quot;RunDaily&quot; = {
        principal  = &quot;events.amazonaws.com&quot;
        source_arn = module.eventbridge.eventbridge_rule_arns[&quot;crons&quot;]
      }
    }
  </code></pre>
  <p>And I have an <code>eventbridge</code> module:</p>
  <pre><code>module &quot;eventbridge&quot; {
    source = &quot;terraform-aws-modules/eventbridge/aws&quot;
    version = &quot;1.14.0&quot;
  
    create_bus   = false
    create_role  = false
    create_rules = true
  
    rules = {
      crons = {
        description         = &quot;deafault&quot;
        schedule_expression = &quot;rate(1 day)&quot;
      }
    }
  
    targets = {
      crons = [
        {
          arn   = module.lambda_function.lambda_function_arn
          input = jsonencode({ &quot;job&quot; : &quot;crons&quot; })
        }
      ]
    }
  }
  </code></pre>
  <p>Now, this works great, as the rule is created and attached properly.</p>
  <p><a href="https://i.stack.imgur.com/h4Miv.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/h4Miv.png" alt="enter image description here" /></a></p>
  <p>But when I want to change the name of the rule along with its description, terraform pickups only the description change:</p>
  <pre><code>module &quot;eventbridge&quot; {
    ...
    rules = {
      crons = {
        description         = &quot;My custom cron rule&quot;
        schedule_expression = &quot;rate(1 day)&quot;
      }
    }
  
    targets = {
      crons = [
        {
          name  = &quot;my-custom-cron-rule-name&quot;
          arn   = module.lambda_function.lambda_function_arn
          input = jsonencode({ &quot;job&quot; : &quot;crons&quot; })
        }
      ]
    }
  }
  </code></pre>
  <p>Plan:</p>
  <pre><code>Terraform will perform the following actions:
  
    # module.eventbridge.aws_cloudwatch_event_rule.this[&quot;crons&quot;] will be updated in-place
    ~ resource &quot;aws_cloudwatch_event_rule&quot; &quot;this&quot; {
        ~ description         = &quot;deafault&quot; -&gt; &quot;My custom cron rule&quot;
          id                  = &quot;crons-rule&quot;
          name                = &quot;crons-rule&quot;
          tags                = {
              &quot;Name&quot; = &quot;crons-rule&quot;
          }
          # (5 unchanged attributes hidden)
      }
  
  Plan: 0 to add, 1 to change, 0 to destroy.
  </code></pre>
  <hr />
  <p><strong>Question:</strong> <em>How do I change the <code>name</code> attribute for an <code>eventbridge</code> rule?</em></p>