Skip to content

Commit

Permalink
feat: Adding two new fields for Instance create_time and update_time
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 458877561
  • Loading branch information
Google APIs authored and copybara-github committed Jul 4, 2022
1 parent ae65014 commit 207bf59
Showing 1 changed file with 22 additions and 10 deletions.
32 changes: 22 additions & 10 deletions google/spanner/admin/instance/v1/spanner_instance_admin.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2021 Google LLC
// Copyright 2022 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -179,7 +179,7 @@ service InstanceAdmin {
// [Instance][google.spanner.admin.instance.v1.Instance], if successful.
//
// Authorization requires `spanner.instances.update` permission on
// resource [name][google.spanner.admin.instance.v1.Instance.name].
// the resource [name][google.spanner.admin.instance.v1.Instance.name].
rpc UpdateInstance(UpdateInstanceRequest) returns (google.longrunning.Operation) {
option (google.api.http) = {
patch: "/v1/{instance.name=projects/*/instances/*}"
Expand Down Expand Up @@ -309,7 +309,7 @@ message InstanceConfig {

// A unique identifier for the instance configuration. Values
// are of the form
// `projects/<project>/instanceConfigs/[a-z][-a-z0-9]*`
// `projects/<project>/instanceConfigs/[a-z][-a-z0-9]*`.
string name = 1;

// The name of this instance configuration as it appears in UIs.
Expand All @@ -319,7 +319,7 @@ message InstanceConfig {
// replication properties.
repeated ReplicaInfo replicas = 3;

// Allowed values of the default_leader schema option for databases in
// Allowed values of the "default_leader" schema option for databases in
// instances that use this instance configuration.
repeated string leader_options = 4;
}
Expand Down Expand Up @@ -367,17 +367,23 @@ message Instance {
// Must be unique per project and between 4 and 30 characters in length.
string display_name = 3 [(google.api.field_behavior) = REQUIRED];

// Required. The number of nodes allocated to this instance. This may be zero
// in API responses for instances that are not yet in state `READY`.
// The number of nodes allocated to this instance. At most one of either
// node_count or processing_units should be present in the message. This
// may be zero in API responses for instances that are not yet in state
// `READY`.
//
// See [the
// documentation](https://cloud.google.com/spanner/docs/instances#node_count)
// for more information about nodes.
// documentation](https://cloud.google.com/spanner/docs/compute-capacity)
// for more information about nodes and processing units.
int32 node_count = 5;

// The number of processing units allocated to this instance. At most one of
// processing_units or node_count should be present in the message. This may
// be zero in API responses for instances that are not yet in state `READY`.
//
// See [the
// documentation](https://cloud.google.com/spanner/docs/compute-capacity)
// for more information about nodes and processing units.
int32 processing_units = 9;

// Output only. The current instance state. For
Expand All @@ -395,9 +401,9 @@ message Instance {
// firewall, load balancing, etc.).
//
// * Label keys must be between 1 and 63 characters long and must conform to
// the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`.
// the following regular expression: `[a-z][a-z0-9_-]{0,62}`.
// * Label values must be between 0 and 63 characters long and must conform
// to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`.
// to the regular expression `[a-z0-9_-]{0,63}`.
// * No more than 64 labels can be associated with a given resource.
//
// See https://goo.gl/xmQnxf for more information on and examples of labels.
Expand All @@ -412,6 +418,12 @@ message Instance {

// Deprecated. This field is not populated.
repeated string endpoint_uris = 8;

// Output only. The time at which the instance was created.
google.protobuf.Timestamp create_time = 11 [(google.api.field_behavior) = OUTPUT_ONLY];

// Output only. The time at which the instance was most recently updated.
google.protobuf.Timestamp update_time = 12 [(google.api.field_behavior) = OUTPUT_ONLY];
}

// The request for [ListInstanceConfigs][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigs].
Expand Down

0 comments on commit 207bf59

Please sign in to comment.