Skip to content

Commit

Permalink
Remove 'id' fields from schemas
Browse files Browse the repository at this point in the history
  • Loading branch information
radeksimko committed Sep 29, 2017
1 parent fbc7b39 commit 0b912da
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 34 deletions.
7 changes: 0 additions & 7 deletions google/resource_compute_ssl_certificate.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package google

import (
"fmt"
"strconv"

"github.com/hashicorp/terraform/helper/resource"
"github.com/hashicorp/terraform/helper/schema"
Expand Down Expand Up @@ -61,11 +60,6 @@ func resourceComputeSslCertificate() *schema.Resource {
ForceNew: true,
},

"id": &schema.Schema{
Type: schema.TypeString,
Computed: true,
},

"project": &schema.Schema{
Type: schema.TypeString,
Optional: true,
Expand Down Expand Up @@ -140,7 +134,6 @@ func resourceComputeSslCertificateRead(d *schema.ResourceData, meta interface{})
}

d.Set("self_link", cert.SelfLink)
d.Set("id", strconv.FormatUint(cert.Id, 10))

return nil
}
Expand Down
7 changes: 0 additions & 7 deletions google/resource_compute_target_http_proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package google
import (
"fmt"
"log"
"strconv"

"github.com/hashicorp/terraform/helper/schema"
"google.golang.org/api/compute/v1"
Expand Down Expand Up @@ -34,11 +33,6 @@ func resourceComputeTargetHttpProxy() *schema.Resource {
ForceNew: true,
},

"id": &schema.Schema{
Type: schema.TypeString,
Computed: true,
},

"project": &schema.Schema{
Type: schema.TypeString,
Optional: true,
Expand Down Expand Up @@ -134,7 +128,6 @@ func resourceComputeTargetHttpProxyRead(d *schema.ResourceData, meta interface{}
}

d.Set("self_link", proxy.SelfLink)
d.Set("id", strconv.FormatUint(proxy.Id, 10))

return nil
}
Expand Down
7 changes: 0 additions & 7 deletions google/resource_compute_target_https_proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package google
import (
"fmt"
"log"
"strconv"

"github.com/hashicorp/terraform/helper/schema"
"google.golang.org/api/compute/v1"
Expand Down Expand Up @@ -55,11 +54,6 @@ func resourceComputeTargetHttpsProxy() *schema.Resource {
Computed: true,
},

"id": &schema.Schema{
Type: schema.TypeString,
Computed: true,
},

"project": &schema.Schema{
Type: schema.TypeString,
Optional: true,
Expand Down Expand Up @@ -178,7 +172,6 @@ func resourceComputeTargetHttpsProxyRead(d *schema.ResourceData, meta interface{

d.Set("ssl_certificates", proxy.SslCertificates)
d.Set("self_link", proxy.SelfLink)
d.Set("id", strconv.FormatUint(proxy.Id, 10))

return nil
}
Expand Down
7 changes: 0 additions & 7 deletions google/resource_compute_url_map.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package google

import (
"fmt"
"strconv"

"github.com/hashicorp/terraform/helper/schema"
"google.golang.org/api/compute/v1"
Expand Down Expand Up @@ -63,11 +62,6 @@ func resourceComputeUrlMap() *schema.Resource {
},
},

"id": &schema.Schema{
Type: schema.TypeString,
Computed: true,
},

"path_matcher": &schema.Schema{
Type: schema.TypeList,
Optional: true,
Expand Down Expand Up @@ -315,7 +309,6 @@ func resourceComputeUrlMapRead(d *schema.ResourceData, meta interface{}) error {

d.SetId(name)
d.Set("self_link", urlMap.SelfLink)
d.Set("id", strconv.FormatUint(urlMap.Id, 10))
d.Set("fingerprint", urlMap.Fingerprint)

hostRuleMap := make(map[string]*compute.HostRule)
Expand Down
6 changes: 0 additions & 6 deletions google/resource_google_project.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,6 @@ func resourceGoogleProject() *schema.Resource {
MigrateState: resourceGoogleProjectMigrateState,

Schema: map[string]*schema.Schema{
"id": &schema.Schema{
Type: schema.TypeString,
Optional: true,
Computed: true,
Removed: "The id field has been removed. Use project_id instead.",
},
"project_id": &schema.Schema{
Type: schema.TypeString,
Required: true,
Expand Down

0 comments on commit 0b912da

Please sign in to comment.