Class: Google::Cloud::Spanner::Admin::Database::V1::Database

Inherits:
Object
  • Object
show all
Extended by:
Protobuf::MessageExts::ClassMethods
Includes:
Protobuf::MessageExts
Defined in:
proto_docs/google/spanner/admin/database/v1/spanner_database_admin.rb

Overview

A Cloud Spanner database.

Defined Under Namespace

Modules: State

Instance Attribute Summary collapse

Instance Attribute Details

#create_time::Google::Protobuf::Timestamp (readonly)

Returns Output only. If exists, the time at which the database creation started.

Returns:



96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# File 'proto_docs/google/spanner/admin/database/v1/spanner_database_admin.rb', line 96

class Database
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Indicates the current state of the database.
  module State
    # Not specified.
    STATE_UNSPECIFIED = 0

    # The database is still being created. Operations on the database may fail
    # with `FAILED_PRECONDITION` in this state.
    CREATING = 1

    # The database is fully created and ready for use.
    READY = 2

    # The database is fully created and ready for use, but is still
    # being optimized for performance and cannot handle full load.
    #
    # In this state, the database still references the backup
    # it was restore from, preventing the backup
    # from being deleted. When optimizations are complete, the full performance
    # of the database will be restored, and the database will transition to
    # `READY` state.
    READY_OPTIMIZING = 3
  end
end

#default_leader::String (readonly)

Returns Output only. The read-write region which contains the database's leader replicas.

This is the same as the value of default_leader database option set using DatabaseAdmin.CreateDatabase or DatabaseAdmin.UpdateDatabaseDdl. If not explicitly set, this is empty.

Returns:

  • (::String)

    Output only. The read-write region which contains the database's leader replicas.

    This is the same as the value of default_leader database option set using DatabaseAdmin.CreateDatabase or DatabaseAdmin.UpdateDatabaseDdl. If not explicitly set, this is empty.



96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# File 'proto_docs/google/spanner/admin/database/v1/spanner_database_admin.rb', line 96

class Database
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Indicates the current state of the database.
  module State
    # Not specified.
    STATE_UNSPECIFIED = 0

    # The database is still being created. Operations on the database may fail
    # with `FAILED_PRECONDITION` in this state.
    CREATING = 1

    # The database is fully created and ready for use.
    READY = 2

    # The database is fully created and ready for use, but is still
    # being optimized for performance and cannot handle full load.
    #
    # In this state, the database still references the backup
    # it was restore from, preventing the backup
    # from being deleted. When optimizations are complete, the full performance
    # of the database will be restored, and the database will transition to
    # `READY` state.
    READY_OPTIMIZING = 3
  end
end

#earliest_version_time::Google::Protobuf::Timestamp (readonly)

Returns Output only. Earliest timestamp at which older versions of the data can be read. This value is continuously updated by Cloud Spanner and becomes stale the moment it is queried. If you are using this value to recover data, make sure to account for the time from the moment when the value is queried to the moment when you initiate the recovery.

Returns:

  • (::Google::Protobuf::Timestamp)

    Output only. Earliest timestamp at which older versions of the data can be read. This value is continuously updated by Cloud Spanner and becomes stale the moment it is queried. If you are using this value to recover data, make sure to account for the time from the moment when the value is queried to the moment when you initiate the recovery.



96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# File 'proto_docs/google/spanner/admin/database/v1/spanner_database_admin.rb', line 96

class Database
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Indicates the current state of the database.
  module State
    # Not specified.
    STATE_UNSPECIFIED = 0

    # The database is still being created. Operations on the database may fail
    # with `FAILED_PRECONDITION` in this state.
    CREATING = 1

    # The database is fully created and ready for use.
    READY = 2

    # The database is fully created and ready for use, but is still
    # being optimized for performance and cannot handle full load.
    #
    # In this state, the database still references the backup
    # it was restore from, preventing the backup
    # from being deleted. When optimizations are complete, the full performance
    # of the database will be restored, and the database will transition to
    # `READY` state.
    READY_OPTIMIZING = 3
  end
end

#encryption_config::Google::Cloud::Spanner::Admin::Database::V1::EncryptionConfig (readonly)

Returns Output only. For databases that are using customer managed encryption, this field contains the encryption configuration for the database. For databases that are using Google default or other types of encryption, this field is empty.

Returns:



96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# File 'proto_docs/google/spanner/admin/database/v1/spanner_database_admin.rb', line 96

class Database
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Indicates the current state of the database.
  module State
    # Not specified.
    STATE_UNSPECIFIED = 0

    # The database is still being created. Operations on the database may fail
    # with `FAILED_PRECONDITION` in this state.
    CREATING = 1

    # The database is fully created and ready for use.
    READY = 2

    # The database is fully created and ready for use, but is still
    # being optimized for performance and cannot handle full load.
    #
    # In this state, the database still references the backup
    # it was restore from, preventing the backup
    # from being deleted. When optimizations are complete, the full performance
    # of the database will be restored, and the database will transition to
    # `READY` state.
    READY_OPTIMIZING = 3
  end
end

#encryption_info::Array<::Google::Cloud::Spanner::Admin::Database::V1::EncryptionInfo> (readonly)

Returns Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use.

For databases that are using Google default or other types of encryption, this field is empty.

This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.

Returns:

  • (::Array<::Google::Cloud::Spanner::Admin::Database::V1::EncryptionInfo>)

    Output only. For databases that are using customer managed encryption, this field contains the encryption information for the database, such as encryption state and the Cloud KMS key versions that are in use.

    For databases that are using Google default or other types of encryption, this field is empty.

    This field is propagated lazily from the backend. There might be a delay from when a key version is being used and when it appears in this field.



96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# File 'proto_docs/google/spanner/admin/database/v1/spanner_database_admin.rb', line 96

class Database
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Indicates the current state of the database.
  module State
    # Not specified.
    STATE_UNSPECIFIED = 0

    # The database is still being created. Operations on the database may fail
    # with `FAILED_PRECONDITION` in this state.
    CREATING = 1

    # The database is fully created and ready for use.
    READY = 2

    # The database is fully created and ready for use, but is still
    # being optimized for performance and cannot handle full load.
    #
    # In this state, the database still references the backup
    # it was restore from, preventing the backup
    # from being deleted. When optimizations are complete, the full performance
    # of the database will be restored, and the database will transition to
    # `READY` state.
    READY_OPTIMIZING = 3
  end
end

#name::String

Returns Required. The name of the database. Values are of the form projects/<project>/instances/<instance>/databases/<database>, where <database> is as specified in the CREATE DATABASE statement. This name can be passed to other API methods to identify the database.

Returns:

  • (::String)

    Required. The name of the database. Values are of the form projects/<project>/instances/<instance>/databases/<database>, where <database> is as specified in the CREATE DATABASE statement. This name can be passed to other API methods to identify the database.



96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# File 'proto_docs/google/spanner/admin/database/v1/spanner_database_admin.rb', line 96

class Database
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Indicates the current state of the database.
  module State
    # Not specified.
    STATE_UNSPECIFIED = 0

    # The database is still being created. Operations on the database may fail
    # with `FAILED_PRECONDITION` in this state.
    CREATING = 1

    # The database is fully created and ready for use.
    READY = 2

    # The database is fully created and ready for use, but is still
    # being optimized for performance and cannot handle full load.
    #
    # In this state, the database still references the backup
    # it was restore from, preventing the backup
    # from being deleted. When optimizations are complete, the full performance
    # of the database will be restored, and the database will transition to
    # `READY` state.
    READY_OPTIMIZING = 3
  end
end

#restore_info::Google::Cloud::Spanner::Admin::Database::V1::RestoreInfo (readonly)

Returns Output only. Applicable only for restored databases. Contains information about the restore source.

Returns:



96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# File 'proto_docs/google/spanner/admin/database/v1/spanner_database_admin.rb', line 96

class Database
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Indicates the current state of the database.
  module State
    # Not specified.
    STATE_UNSPECIFIED = 0

    # The database is still being created. Operations on the database may fail
    # with `FAILED_PRECONDITION` in this state.
    CREATING = 1

    # The database is fully created and ready for use.
    READY = 2

    # The database is fully created and ready for use, but is still
    # being optimized for performance and cannot handle full load.
    #
    # In this state, the database still references the backup
    # it was restore from, preventing the backup
    # from being deleted. When optimizations are complete, the full performance
    # of the database will be restored, and the database will transition to
    # `READY` state.
    READY_OPTIMIZING = 3
  end
end

#state::Google::Cloud::Spanner::Admin::Database::V1::Database::State (readonly)

Returns Output only. The current database state.

Returns:



96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# File 'proto_docs/google/spanner/admin/database/v1/spanner_database_admin.rb', line 96

class Database
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Indicates the current state of the database.
  module State
    # Not specified.
    STATE_UNSPECIFIED = 0

    # The database is still being created. Operations on the database may fail
    # with `FAILED_PRECONDITION` in this state.
    CREATING = 1

    # The database is fully created and ready for use.
    READY = 2

    # The database is fully created and ready for use, but is still
    # being optimized for performance and cannot handle full load.
    #
    # In this state, the database still references the backup
    # it was restore from, preventing the backup
    # from being deleted. When optimizations are complete, the full performance
    # of the database will be restored, and the database will transition to
    # `READY` state.
    READY_OPTIMIZING = 3
  end
end

#version_retention_period::String (readonly)

Returns Output only. The period in which Cloud Spanner retains all versions of data for the database. This is the same as the value of version_retention_period database option set using UpdateDatabaseDdl. Defaults to 1 hour, if not set.

Returns:

  • (::String)

    Output only. The period in which Cloud Spanner retains all versions of data for the database. This is the same as the value of version_retention_period database option set using UpdateDatabaseDdl. Defaults to 1 hour, if not set.



96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
# File 'proto_docs/google/spanner/admin/database/v1/spanner_database_admin.rb', line 96

class Database
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Indicates the current state of the database.
  module State
    # Not specified.
    STATE_UNSPECIFIED = 0

    # The database is still being created. Operations on the database may fail
    # with `FAILED_PRECONDITION` in this state.
    CREATING = 1

    # The database is fully created and ready for use.
    READY = 2

    # The database is fully created and ready for use, but is still
    # being optimized for performance and cannot handle full load.
    #
    # In this state, the database still references the backup
    # it was restore from, preventing the backup
    # from being deleted. When optimizations are complete, the full performance
    # of the database will be restored, and the database will transition to
    # `READY` state.
    READY_OPTIMIZING = 3
  end
end