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

Added deprecation message in hcp consul resources and data sources #1124

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .changelog/1124.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
```release-note:deprecation
Added a Deprecation message for the following resources: `hcp_consul_cluster`,`hcp_consul_cluster_root_token`,`hcp_consul_snapshot`
```

```release-note:deprecation
Added a Deprecation message for the following resources: `hcp_consul_agent_helm_config`,`hcp_consul_agent_kubernetes_secret`,`hcp_consul_cluster`,`hcp_consul_versions`
```
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ connectInject:

func dataSourceConsulAgentHelmConfig() *schema.Resource {
return &schema.Resource{
Description: "The Consul agent Helm config data source provides Helm values for a Consul agent running in Kubernetes.",
DeprecationMessage: "HashiCorp plans to sunset HashiCorp Consul Dedicated (HCD) in November 2025, more information about the EOL will be provided to existing customers directly",
Description: "The Consul agent Helm config data source provides Helm values for a Consul agent running in Kubernetes.",
Timeouts: &schema.ResourceTimeout{
Default: &defaultConsulAgentHelmConfigTimeoutDuration,
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,9 @@ data:

func dataSourceConsulAgentKubernetesSecret() *schema.Resource {
return &schema.Resource{
Description: "The agent config Kubernetes secret data source provides Consul agents running in Kubernetes the configuration needed to connect to the Consul cluster.",
ReadContext: dataSourceConsulAgentKubernetesSecretRead,
DeprecationMessage: "HashiCorp plans to sunset HashiCorp Consul Dedicated (HCD) in November 2025, more information about the EOL will be provided to existing customers directly",
Description: "The agent config Kubernetes secret data source provides Consul agents running in Kubernetes the configuration needed to connect to the Consul cluster.",
ReadContext: dataSourceConsulAgentKubernetesSecretRead,
Timeouts: &schema.ResourceTimeout{
Default: &defaultAgentConfigKubernetesSecretTimeoutDuration,
},
Expand Down
5 changes: 3 additions & 2 deletions internal/providersdkv2/data_source_consul_cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,9 @@ import (

func dataSourceConsulCluster() *schema.Resource {
return &schema.Resource{
Description: "The cluster data source provides information about an existing HCP Consul cluster.",
ReadContext: dataSourceConsulClusterRead,
DeprecationMessage: "HashiCorp plans to sunset HashiCorp Consul Dedicated (HCD) in November 2025, more information about the EOL will be provided to existing customers directly",
Description: "The cluster data source provides information about an existing HCP Consul cluster.",
ReadContext: dataSourceConsulClusterRead,
Timeouts: &schema.ResourceTimeout{
Default: &defaultConsulClusterTimeout,
},
Expand Down
3 changes: 2 additions & 1 deletion internal/providersdkv2/data_source_consul_versions.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ var defaultConsulVersionsTimeoutDuration = time.Minute * 5
// dataSourceConsulVersions is the data source for the Consul versions supported by HCP.
func dataSourceConsulVersions() *schema.Resource {
return &schema.Resource{
Description: "The Consul versions data source provides the Consul versions supported by HCP.",
DeprecationMessage: "HashiCorp plans to sunset HashiCorp Consul Dedicated (HCD) in November 2025, more information about the EOL will be provided to existing customers directly",
Description: "The Consul versions data source provides the Consul versions supported by HCP.",
Timeouts: &schema.ResourceTimeout{
Default: &defaultConsulVersionsTimeoutDuration,
},
Expand Down
11 changes: 6 additions & 5 deletions internal/providersdkv2/resource_consul_cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,12 @@ var deleteConsulClusterTimeout = time.Minute * 35
// resourceConsulCluster represents an HCP Consul cluster.
func resourceConsulCluster() *schema.Resource {
return &schema.Resource{
Description: "The Consul cluster resource allows you to manage an HCP Consul cluster.",
CreateContext: resourceConsulClusterCreate,
ReadContext: resourceConsulClusterRead,
UpdateContext: resourceConsulClusterUpdate,
DeleteContext: resourceConsulClusterDelete,
DeprecationMessage: "HashiCorp plans to sunset HashiCorp Consul Dedicated (HCD) in November 2025, more information about the EOL will be provided to existing customers directly",
Description: "The Consul cluster resource allows you to manage an HCP Consul cluster.",
CreateContext: resourceConsulClusterCreate,
ReadContext: resourceConsulClusterRead,
UpdateContext: resourceConsulClusterUpdate,
DeleteContext: resourceConsulClusterDelete,
Timeouts: &schema.ResourceTimeout{
Default: &defaultConsulClusterTimeout,
Create: &createUpdateConsulClusterTimeout,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ data:
// resourceConsulClusterRootToken represents an HCP Consul cluster.
func resourceConsulClusterRootToken() *schema.Resource {
return &schema.Resource{
DeprecationMessage: "HashiCorp plans to sunset HashiCorp Consul Dedicated (HCD) in November 2025, more information about the EOL will be provided to existing customers directly",
Description: "The cluster root token resource is the token used to bootstrap the cluster's ACL system. " +
"You can also generate this root token from the HCP Consul UI.",
CreateContext: resourceConsulClusterRootTokenCreate,
Expand Down
1 change: 1 addition & 0 deletions internal/providersdkv2/resource_consul_snapshot.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ var snapshotCreateUpdateDeleteTimeoutDuration = time.Minute * 15

func resourceConsulSnapshot() *schema.Resource {
return &schema.Resource{
DeprecationMessage: "HashiCorp plans to sunset HashiCorp Consul Dedicated (HCD) in November 2025, more information about the EOL will be provided to existing customers directly",
Description: "The Consul snapshot resource allows users to manage Consul snapshots of an HCP Consul cluster. " +
"Snapshots currently have a retention policy of 30 days.",
CreateContext: resourceConsulSnapshotCreate,
Expand Down