@@ -76,12 +76,6 @@ func resourceMemcacheInstance() *schema.Resource {
7676 Required : true ,
7777 Description : `Number of nodes in the memcache instance.` ,
7878 },
79- "region" : {
80- Type : schema .TypeString ,
81- Required : true ,
82- ForceNew : true ,
83- Description : `The name of the Memcache region of the instance.` ,
84- },
8579 "authorized_network" : {
8680 Type : schema .TypeString ,
8781 Optional : true ,
@@ -132,6 +126,13 @@ Currently the latest supported major version is MEMCACHE_1_5. The minor version
132126determined by our system based on the latest supported minor version. Default value: "MEMCACHE_1_5" Possible values: ["MEMCACHE_1_5"]` ,
133127 Default : "MEMCACHE_1_5" ,
134128 },
129+ "region" : {
130+ Type : schema .TypeString ,
131+ Computed : true ,
132+ Optional : true ,
133+ ForceNew : true ,
134+ Description : `The region of the Memcache instance. If it is not provided, the provider region is used.` ,
135+ },
135136 "zones" : {
136137 Type : schema .TypeSet ,
137138 Computed : true ,
@@ -350,14 +351,6 @@ func resourceMemcacheInstanceRead(d *schema.ResourceData, meta interface{}) erro
350351 return fmt .Errorf ("Error reading Instance: %s" , err )
351352 }
352353
353- region , err := getRegion (d , config )
354- if err != nil {
355- return err
356- }
357- if err := d .Set ("region" , region ); err != nil {
358- return fmt .Errorf ("Error reading Instance: %s" , err )
359- }
360-
361354 if err := d .Set ("display_name" , flattenMemcacheInstanceDisplayName (res ["displayName" ], d , config )); err != nil {
362355 return fmt .Errorf ("Error reading Instance: %s" , err )
363356 }
0 commit comments