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

terraform: Emit lifecycle phases of ephemeral resources to the UI #35919

Merged
merged 1 commit into from
Oct 30, 2024

Conversation

radeksimko
Copy link
Member

@radeksimko radeksimko commented Oct 29, 2024

UX

$ terraform plan
data.local_file.foo: Reading...
ephemeral.random_password.example: Opening...
data.local_file.foo: Read complete after 0s [id=a94a8fe5ccb19ba61c4c0873d391e987982fbbd3]
ephemeral.random_password.example: Opening complete after 0s
ephemeral.random_password.example: Closing...
ephemeral.random_password.example: Closing complete after 0s

No changes. Your infrastructure matches the configuration.

Terraform has compared your real infrastructure against your configuration and found no differences, so no changes are needed.
$ terraform apply
ephemeral.random_password.example: Opening...
data.local_file.foo: Reading...
data.local_file.foo: Read complete after 0s [id=a94a8fe5ccb19ba61c4c0873d391e987982fbbd3]
ephemeral.random_password.example: Opening complete after 0s
ephemeral.random_password.example: Closing...
ephemeral.random_password.example: Closing complete after 0s

No changes. Your infrastructure matches the configuration.

Terraform has compared your real infrastructure against your configuration and found no differences, so no changes are needed.
ephemeral.random_password.example: Opening...
ephemeral.random_password.example: Opening complete after 0s
ephemeral.random_password.example: Closing...
ephemeral.random_password.example: Closing complete after 0s

Apply complete! Resources: 0 added, 0 changed, 0 destroyed.

Outputs:

foo = "test"

It may look a bit verbose but I think it reflects the reality that ephemeral resources go always through a fresh lifecycle again during apply, so I don't it's wrong.


I will look into updating any TFC related logic or coordinate with the CLI team.

cc @hashicorp/tf-editor-experience-engineers FYI this may impact you in the context of https://github.com/hashicorp/vscode-terraform/blob/87ceb0ac381fb3ee9417682e3ff0954115351553/src/api/terraformCloud/log.ts#L26-L58

@radeksimko radeksimko force-pushed the radek/ephemeral-resources-ui branch from 5722d4d to 61080a0 Compare October 29, 2024 15:53
@radeksimko radeksimko force-pushed the radek/ephemeral-resources-ui branch from 61080a0 to 42ba5d2 Compare October 29, 2024 16:03
@radeksimko radeksimko force-pushed the radek/ephemeral-resources-ui branch 3 times, most recently from e1a580d to 2bc0df2 Compare October 29, 2024 17:44
@radeksimko radeksimko force-pushed the radek/ephemeral-resources-ui branch from 2bc0df2 to 5d15e4c Compare October 29, 2024 17:56
@radeksimko radeksimko force-pushed the radek/ephemeral-resources-ui branch from 5d15e4c to 3470e96 Compare October 29, 2024 18:04
@radeksimko radeksimko force-pushed the radek/ephemeral-resources-ui branch from 3470e96 to 7359d7e Compare October 29, 2024 18:09
@radeksimko radeksimko force-pushed the radek/ephemeral-resources-ui branch 2 times, most recently from 64748a5 to 2780a32 Compare October 29, 2024 18:18
@radeksimko radeksimko force-pushed the radek/ephemeral-resources-ui branch from 2780a32 to c58d62e Compare October 30, 2024 09:31
@radeksimko radeksimko force-pushed the radek/ephemeral-resources-ui branch from c58d62e to 958fc40 Compare October 30, 2024 10:01
@radeksimko radeksimko force-pushed the radek/ephemeral-resources-ui branch from 958fc40 to 35221b9 Compare October 30, 2024 10:56
@radeksimko radeksimko merged commit 0a266c8 into main Oct 30, 2024
11 checks passed
@radeksimko radeksimko deleted the radek/ephemeral-resources-ui branch October 30, 2024 12:44
Copy link
Contributor

Reminder for the merging maintainer: if this is a user-visible change, please update the changelog on the appropriate release branch.

jpogran added a commit to hashicorp/vscode-terraform that referenced this pull request Nov 18, 2024
This commit adds the ephemeral lifecycle messages to the log message type. This will allow the UI to display the progress of ephemeral operations.

This uses messages from hashicorp/terraform#35919, which matches the messages from the HCP API.
jpogran added a commit to hashicorp/vscode-terraform that referenced this pull request Nov 18, 2024
This commit adds the ephemeral lifecycle messages to the log message type. This will allow the UI to display the progress of ephemeral operations.

This uses messages from hashicorp/terraform#35919, which matches the messages from the HCP API.
jpogran added a commit to hashicorp/vscode-terraform that referenced this pull request Nov 25, 2024
This commit adds the ephemeral lifecycle messages to the log message type. This will allow the UI to display the progress of ephemeral operations.

This uses messages from hashicorp/terraform#35919, which matches the messages from the HCP API.
jpogran added a commit to hashicorp/vscode-terraform that referenced this pull request Nov 25, 2024
* (TFECO-8141) Add ephemeral lifecycle messages

This commit adds the ephemeral lifecycle messages to the log message type. This will allow the UI to display the progress of ephemeral operations.

This uses messages from hashicorp/terraform#35919, which matches the messages from the HCP API.
Copy link
Contributor

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active contributions.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 30, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants