Skip to content

Commit 8f742bd

Browse files
committed
Removed Managed Redis references
1 parent 14bf6e0 commit 8f742bd

8 files changed

+27
-35
lines changed

vultr/data_source_vultr_database.go

+5-5
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ func dataSourceVultrDatabaseRead(ctx context.Context, d *schema.ResourceData, me
212212
return diag.Errorf("unable to set resource database `plan` read value: %v", err)
213213
}
214214

215-
if databaseList[0].DatabaseEngine != "redis" && databaseList[0].DatabaseEngine != "valkey" {
215+
if databaseList[0].DatabaseEngine != "valkey" {
216216
if err := d.Set("plan_disk", databaseList[0].PlanDisk); err != nil {
217217
return diag.Errorf("unable to set resource database `plan_disk` read value: %v", err)
218218
}
@@ -346,13 +346,13 @@ func dataSourceVultrDatabaseRead(ctx context.Context, d *schema.ResourceData, me
346346
}
347347
}
348348

349-
if databaseList[0].DatabaseEngine == "redis" || databaseList[0].DatabaseEngine == "valkey" {
349+
if databaseList[0].DatabaseEngine == "valkey" {
350350
if err := d.Set("eviction_policy", databaseList[0].EvictionPolicy); err != nil {
351351
return diag.Errorf("unable to set resource database `eviction_policy` read value: %v", err)
352352
}
353353
}
354354

355-
if databaseList[0].DatabaseEngine != "redis" && databaseList[0].DatabaseEngine != "valkey" {
355+
if databaseList[0].DatabaseEngine != "valkey" {
356356
if err := d.Set("cluster_time_zone", databaseList[0].ClusterTimeZone); err != nil {
357357
return diag.Errorf("unable to set resource database `cluster_time_zone` read value: %v", err)
358358
}
@@ -433,11 +433,11 @@ func flattenReplicas(db *govultr.Database) []map[string]interface{} {
433433
delete(r, "mysql_sql_long_query_time")
434434
}
435435

436-
if db.DatabaseEngine != "redis" && db.DatabaseEngine != "valkey" {
436+
if db.DatabaseEngine != "valkey" {
437437
delete(r, "eviction_policy")
438438
}
439439

440-
if db.DatabaseEngine == "redis" || db.DatabaseEngine == "valkey" {
440+
if db.DatabaseEngine == "valkey" {
441441
delete(r, "cluster_time_zone")
442442
}
443443

vultr/resource_vultr_database.go

+5-5
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ func resourceVultrDatabaseCreate(ctx context.Context, d *schema.ResourceData, me
269269
}
270270

271271
// Default user (vultradmin) password can only be changed after creation
272-
if password, passwordOK := d.GetOk("password"); passwordOK && d.Get("database_engine").(string) != "redis" && d.Get("database_engine").(string) != "valkey" { //nolint:lll
272+
if password, passwordOK := d.GetOk("password"); passwordOK && d.Get("database_engine").(string) != "valkey" { //nolint:lll
273273
req3 := &govultr.DatabaseUserUpdateReq{
274274
Password: password.(string),
275275
}
@@ -304,7 +304,7 @@ func resourceVultrDatabaseRead(ctx context.Context, d *schema.ResourceData, meta
304304
return diag.Errorf("unable to set resource database `plan` read value: %v", err)
305305
}
306306

307-
if database.DatabaseEngine != "redis" && database.DatabaseEngine != "valkey" {
307+
if database.DatabaseEngine != "valkey" {
308308
if err := d.Set("plan_disk", database.PlanDisk); err != nil {
309309
return diag.Errorf("unable to set resource database `plan_disk` read value: %v", err)
310310
}
@@ -438,13 +438,13 @@ func resourceVultrDatabaseRead(ctx context.Context, d *schema.ResourceData, meta
438438
}
439439
}
440440

441-
if database.DatabaseEngine == "redis" || database.DatabaseEngine == "valkey" {
441+
if database.DatabaseEngine == "valkey" {
442442
if err := d.Set("eviction_policy", database.EvictionPolicy); err != nil {
443443
return diag.Errorf("unable to set resource database `eviction_policy` read value: %v", err)
444444
}
445445
}
446446

447-
if database.DatabaseEngine != "redis" && database.DatabaseEngine != "valkey" {
447+
if database.DatabaseEngine != "valkey" {
448448
if err := d.Set("cluster_time_zone", database.ClusterTimeZone); err != nil {
449449
return diag.Errorf("unable to set resource database `cluster_time_zone` read value: %v", err)
450450
}
@@ -581,7 +581,7 @@ func resourceVultrDatabaseUpdate(ctx context.Context, d *schema.ResourceData, me
581581
}
582582

583583
// Updating the default user password requires a separate API call
584-
if d.HasChange("password") && d.Get("database_engine").(string) != "redis" && d.Get("database_engine").(string) != "valkey" { //nolint:lll
584+
if d.HasChange("password") && d.Get("database_engine").(string) != "valkey" {
585585
_, newVal := d.GetChange("password")
586586
password := newVal.(string)
587587
reqP := &govultr.DatabaseUserUpdateReq{

vultr/resource_vultr_database_replica.go

+3-3
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ func resourceVultrDatabaseReplicaRead(ctx context.Context, d *schema.ResourceDat
102102
return diag.Errorf("unable to set resource database read replica `plan` read value: %v", err)
103103
}
104104

105-
if database.DatabaseEngine != "redis" && database.DatabaseEngine != "valkey" {
105+
if database.DatabaseEngine != "valkey" {
106106
if err := d.Set("plan_disk", database.PlanDisk); err != nil {
107107
return diag.Errorf("unable to set resource database read replica `plan_disk` read value: %v", err)
108108
}
@@ -229,7 +229,7 @@ func resourceVultrDatabaseReplicaRead(ctx context.Context, d *schema.ResourceDat
229229
}
230230
}
231231

232-
if database.DatabaseEngine == "redis" || database.DatabaseEngine == "valkey" {
232+
if database.DatabaseEngine == "valkey" {
233233
if err := d.Set("eviction_policy", database.EvictionPolicy); err != nil {
234234
return diag.Errorf(
235235
"unable to set resource database read replica `eviction_policy` read value: %v",
@@ -238,7 +238,7 @@ func resourceVultrDatabaseReplicaRead(ctx context.Context, d *schema.ResourceDat
238238
}
239239
}
240240

241-
if database.DatabaseEngine != "redis" && database.DatabaseEngine != "valkey" {
241+
if database.DatabaseEngine != "valkey" {
242242
if err := d.Set("cluster_time_zone", database.ClusterTimeZone); err != nil {
243243
return diag.Errorf("unable to set resource database read replica `cluster_time_zone` read value: %v", err)
244244
}

vultr/resource_vultr_database_user.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ func resourceVultrDatabaseUserCreate(ctx context.Context, d *schema.ResourceData
8989

9090
d.SetId(databaseUser.Username)
9191

92-
// Redis/Valkey user access control can only be updated after creation
92+
// Valkey user access control can only be updated after creation
9393
if accessControl, accessControlOK := d.GetOk("access_control"); accessControlOK {
9494
if err := updateUserACL(ctx, client, databaseID, d, accessControl); err != nil {
9595
return diag.Errorf("error updating user access control: %v", err)

website/docs/d/database.html.markdown

+1-2
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,6 @@ The following attributes are exported:
6969
* `mysql_require_primary_key` - The configuration value for whether primary keys are required on the managed database (MySQL engine types only).
7070
* `mysql_slow_query_log` - The configuration value for slow query logging on the managed database (MySQL engine types only).
7171
* `mysql_long_query_time` - The configuration value for the long query time (in seconds) on the managed database (MySQL engine types only).
72-
* `redis_eviction_policy` - (Deprecated: use `eviction_policy` instead) The configuration value for the data eviction policy on the managed database (Redis engine types only).
73-
* `eviction_policy` - The configuration value for the data eviction policy on the managed database (Redis engine types only).
72+
* `eviction_policy` - The configuration value for the data eviction policy on the managed database (Valkey engine types only).
7473
* `cluster_time_zone` - The configured time zone for the Managed Database in TZ database format.
7574
* `read_replicas` - A list of read replicas attached to the managed database.

website/docs/r/database.html.markdown

+2-4
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,7 @@ The following arguments are supported:
6464
* `mysql_require_primary_key` - (Optional) The configuration value for whether primary keys are required on the managed database (MySQL engine types only).
6565
* `mysql_slow_query_log` - (Optional) The configuration value for slow query logging on the managed database (MySQL engine types only).
6666
* `mysql_long_query_time` - (Optional) The configuration value for the long query time (in seconds) on the managed database (MySQL engine types only).
67-
* `redis_eviction_policy` - (Deprecated: use `eviction_policy` instead) The configuration value for the data eviction policy on the managed database (Redis engine types only).
68-
* `eviction_policy` - (Optional) The configuration value for the data eviction policy on the managed database (Redis engine types only - `noeviction`, `allkeys-lru`, `volatile-lru`, `allkeys-random`, `volatile-random`, `volatile-ttl`, `volatile-lfu`, `allkeys-lfu`).
67+
* `eviction_policy` - (Optional) The configuration value for the data eviction policy on the managed database (Valkey engine types only - `noeviction`, `allkeys-lru`, `volatile-lru`, `allkeys-random`, `volatile-random`, `volatile-ttl`, `volatile-lfu`, `allkeys-lfu`).
6968

7069
## Attributes Reference
7170

@@ -104,8 +103,7 @@ The following attributes are exported:
104103
* `mysql_require_primary_key` - The configuration value for whether primary keys are required on the managed database (MySQL engine types only).
105104
* `mysql_slow_query_log` - The configuration value for slow query logging on the managed database (MySQL engine types only).
106105
* `mysql_long_query_time` - The configuration value for the long query time (in seconds) on the managed database (MySQL engine types only).
107-
* `redis_eviction_policy` - (Deprecated: use `eviction_policy` instead) The configuration value for the data eviction policy on the managed database (Redis engine types only).
108-
* `eviction_policy` - The configuration value for the data eviction policy on the managed database (Redis engine types only).
106+
* `eviction_policy` - The configuration value for the data eviction policy on the managed database (Valkey engine types only).
109107
* `cluster_time_zone` - The configured time zone for the Managed Database in TZ database format.
110108
* `read_replicas` - A list of read replicas attached to the managed database.
111109

website/docs/r/database_replica.html.markdown

+1-2
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,5 @@ The following attributes are exported:
6969
* `mysql_require_primary_key` - The configuration value for whether primary keys are required on the managed database read replica (MySQL engine types only).
7070
* `mysql_slow_query_log` - The configuration value for slow query logging on the managed database read replica (MySQL engine types only).
7171
* `mysql_long_query_time` - The configuration value for the long query time (in seconds) on the managed database read replica (MySQL engine types only).
72-
* `redis_eviction_policy` - (Deprecated: use `eviction_policy` instead) The configuration value for the data eviction policy on the managed database read replica (Redis engine types only).
73-
* `eviction_policy` - The configuration value for the data eviction policy on the managed database read replica (Redis engine types only).
72+
* `eviction_policy` - The configuration value for the data eviction policy on the managed database read replica (Valkey engine types only).
7473
* `cluster_time_zone` - The configured time zone for the managed database read replica in TZ database format.

website/docs/r/database_user.html.markdown

+9-13
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,12 @@ The following arguments are supported:
3535
* `encryption` - (Optional) The encryption type of the new managed database user's password (MySQL engine types only - `caching_sha2_password`, `mysql_native_password`).
3636
* `permission` - (Optional) The permission level for the database user (Kafka engine types only - `admin`, `read`, `write`, `readwrite`).
3737

38-
`access_control` - (Optional) The access control configuration for the new managed database user (Redis engine types only). It supports the following fields:
38+
`access_control` - (Optional) The access control configuration for the new managed database user (Valkey engine types only). It supports the following fields:
3939

40-
* `redis_acl_categories` - (Required) The list of command category rules for this managed database user.
41-
* `redis_acl_channels` - (Required) The list of publish/subscribe channel patterns for this managed database user.
42-
* `redis_acl_commands` - (Required) The list of individual command rules for this managed database user.
43-
* `redis_acl_keys` - (Required) The list of access rules for this managed database user.
40+
* `acl_categories` - (Required) The list of command category rules for this managed database user.
41+
* `acl_channels` - (Required) The list of publish/subscribe channel patterns for this managed database user.
42+
* `acl_commands` - (Required) The list of individual command rules for this managed database user.
43+
* `acl_keys` - (Required) The list of access rules for this managed database user.
4444

4545
## Attributes Reference
4646

@@ -54,11 +54,7 @@ The following attributes are exported:
5454

5555
`access_control`
5656

57-
* `redis_acl_categories` - (Deprecated: use `acl_categories` instead) List of command category rules for this managed database user (Redis engine types only).
58-
* `redis_acl_channels` - (Deprecated: use `acl_channels` instead) List of publish/subscribe channel patterns for this managed database user (Redis engine types only).
59-
* `redis_acl_commands` - (Deprecated: use `acl_commands` instead) List of individual command rules for this managed database user (Redis engine types only).
60-
* `redis_acl_keys` - (Deprecated: use `acl_keys` instead) List of access rules for this managed database user (Redis engine types only).
61-
* `acl_categories` - List of command category rules for this managed database user (Redis engine types only).
62-
* `acl_channels` - List of publish/subscribe channel patterns for this managed database user (Redis engine types only).
63-
* `acl_commands` - List of individual command rules for this managed database user (Redis engine types only).
64-
* `acl_keys` - List of access rules for this managed database user (Redis engine types only).
57+
* `acl_categories` - List of command category rules for this managed database user (Valkey engine types only).
58+
* `acl_channels` - List of publish/subscribe channel patterns for this managed database user (Valkey engine types only).
59+
* `acl_commands` - List of individual command rules for this managed database user (Valkey engine types only).
60+
* `acl_keys` - List of access rules for this managed database user (Valkey engine types only).

0 commit comments

Comments
 (0)