Skip to content

Commit 34ff4be

Browse files
committed
rdb changes needed for 1st gen success
1 parent c6423eb commit 34ff4be

File tree

3 files changed

+18
-58
lines changed

3 files changed

+18
-58
lines changed

internal/services/documentdb/read_replica.go

+7-27
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,15 @@ func ResourceReadReplica() *schema.Resource {
4949
Optional: true,
5050
Description: "Direct access endpoint, it gives you an IP and a port to access your read-replica",
5151
MaxItems: 1,
52+
Elem: &schema.Resource{},
53+
},
54+
"endpoints_spec": {
55+
Type: schema.TypeList,
56+
Computed: true,
57+
Description: "Endpoints specs",
5258
Elem: &schema.Resource{
5359
Schema: map[string]*schema.Schema{
54-
// Endpoints common
60+
// Endpoints common specs
5561
"endpoint_id": {
5662
Type: schema.TypeString,
5763
Description: "UUID of the endpoint (UUID format).",
@@ -107,32 +113,6 @@ func ResourceReadReplica() *schema.Resource {
107113
Description: "Private network zone",
108114
Computed: true,
109115
},
110-
// Endpoints common
111-
"endpoint_id": {
112-
Type: schema.TypeString,
113-
Description: "UUID of the endpoint (UUID format).",
114-
Computed: true,
115-
},
116-
"ip": {
117-
Type: schema.TypeString,
118-
Description: "IPv4 address of the endpoint (IP address). Only one of ip and hostname may be set",
119-
Computed: true,
120-
},
121-
"port": {
122-
Type: schema.TypeInt,
123-
Description: "TCP port of the endpoint",
124-
Computed: true,
125-
},
126-
"name": {
127-
Type: schema.TypeString,
128-
Description: "Name of the endpoints",
129-
Computed: true,
130-
},
131-
"hostname": {
132-
Type: schema.TypeString,
133-
Description: "Hostname of the endpoint. Only one of ip and hostname may be set",
134-
Computed: true,
135-
},
136116
},
137117
},
138118
},

internal/services/rdb/read_replica.go

+7-27
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,15 @@ func ResourceReadReplica() *schema.Resource {
5555
Optional: true,
5656
Description: "Direct access endpoint, it gives you an IP and a port to access your read-replica",
5757
MaxItems: 1,
58+
Elem: &schema.Resource{},
59+
},
60+
"endpoints_spec": {
61+
Type: schema.TypeList,
62+
Computed: true,
63+
Description: "Endpoints specs",
5864
Elem: &schema.Resource{
5965
Schema: map[string]*schema.Schema{
60-
// Endpoints common
66+
// Endpoints common specs
6167
"endpoint_id": {
6268
Type: schema.TypeString,
6369
Description: "UUID of the endpoint (UUID format).",
@@ -119,32 +125,6 @@ func ResourceReadReplica() *schema.Resource {
119125
Description: "Private network zone",
120126
Computed: true,
121127
},
122-
// Endpoints common
123-
"endpoint_id": {
124-
Type: schema.TypeString,
125-
Description: "UUID of the endpoint (UUID format).",
126-
Computed: true,
127-
},
128-
"ip": {
129-
Type: schema.TypeString,
130-
Description: "IPv4 address of the endpoint (IP address). Only one of ip and hostname may be set",
131-
Computed: true,
132-
},
133-
"port": {
134-
Type: schema.TypeInt,
135-
Description: "TCP port of the endpoint",
136-
Computed: true,
137-
},
138-
"name": {
139-
Type: schema.TypeString,
140-
Description: "Name of the endpoints",
141-
Computed: true,
142-
},
143-
"hostname": {
144-
Type: schema.TypeString,
145-
Description: "Hostname of the endpoint. Only one of ip and hostname may be set",
146-
Computed: true,
147-
},
148128
},
149129
},
150130
},

internal/services/redis/cluster.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -168,10 +168,10 @@ func ResourceCluster() *schema.Resource {
168168
},
169169
// Computed
170170
"public_network": {
171-
Type: schema.TypeList,
172-
Optional: true,
173-
Computed: true,
174-
MaxItems: 1,
171+
Type: schema.TypeList,
172+
//Optional: true,
173+
Computed: true,
174+
//MaxItems: 1,
175175
Description: "Public network specs details",
176176
Elem: &schema.Resource{
177177
Schema: map[string]*schema.Schema{

0 commit comments

Comments
 (0)