Class: Appwrite::Models::DedicatedDatabase

Inherits:
Object
  • Object
show all
Defined in:
lib/appwrite/models/dedicated_database.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id:, created_at:, updated_at:, project_id:, name:, api:, engine:, version:, specification:, backend:, hostname:, connection_port:, connection_user:, connection_password:, connection_string:, ssl:, status:, container_status:, last_accessed_at:, idle_until:, lifecycle_state:, idle_timeout_minutes:, cpu:, memory:, storage:, storage_class:, storage_max_gb:, node_pool:, replicas:, sync_mode:, cross_region_replicas:, network_max_connections:, network_idle_timeout_seconds:, network_ip_allowlist:, backup_enabled:, pitr:, pitr_retention_days:, storage_autoscaling:, storage_autoscaling_threshold_percent:, storage_autoscaling_max_gb:, maintenance_window_day:, maintenance_window_hour_utc:, metrics_enabled:, sql_api_enabled:, sql_api_allowed_statements:, sql_api_max_rows:, sql_api_max_bytes:, sql_api_timeout_seconds:, error:) ⇒ DedicatedDatabase

Returns a new instance of DedicatedDatabase.



56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
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
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
# File 'lib/appwrite/models/dedicated_database.rb', line 56

def initialize(
    id:,
    created_at:,
    updated_at:,
    project_id:,
    name:,
    api:,
    engine:,
    version:,
    specification:,
    backend:,
    hostname:,
    connection_port:,
    connection_user:,
    connection_password:,
    connection_string:,
    ssl:,
    status:,
    container_status:,
    last_accessed_at: ,
    idle_until: ,
    lifecycle_state:,
    idle_timeout_minutes:,
    cpu:,
    memory:,
    storage:,
    storage_class:,
    storage_max_gb:,
    node_pool:,
    replicas:,
    sync_mode:,
    cross_region_replicas:,
    network_max_connections:,
    network_idle_timeout_seconds:,
    network_ip_allowlist:,
    backup_enabled:,
    pitr:,
    pitr_retention_days:,
    storage_autoscaling:,
    storage_autoscaling_threshold_percent:,
    storage_autoscaling_max_gb:,
    maintenance_window_day:,
    maintenance_window_hour_utc:,
    metrics_enabled:,
    sql_api_enabled:,
    sql_api_allowed_statements:,
    sql_api_max_rows:,
    sql_api_max_bytes:,
    sql_api_timeout_seconds:,
    error:
)
    @id = id
    @created_at = created_at
    @updated_at = updated_at
    @project_id = project_id
    @name = name
    @api = api
    @engine = engine
    @version = version
    @specification = specification
    @backend = backend
    @hostname = hostname
    @connection_port = connection_port
    @connection_user = connection_user
    @connection_password = connection_password
    @connection_string = connection_string
    @ssl = ssl
    @status = status
    @container_status = container_status
    @last_accessed_at = last_accessed_at
    @idle_until = idle_until
    @lifecycle_state = lifecycle_state
    @idle_timeout_minutes = idle_timeout_minutes
    @cpu = cpu
    @memory = memory
    @storage = storage
    @storage_class = storage_class
    @storage_max_gb = storage_max_gb
    @node_pool = node_pool
    @replicas = replicas
    @sync_mode = sync_mode
    @cross_region_replicas = cross_region_replicas
    @network_max_connections = network_max_connections
    @network_idle_timeout_seconds = network_idle_timeout_seconds
    @network_ip_allowlist = network_ip_allowlist
    @backup_enabled = backup_enabled
    @pitr = pitr
    @pitr_retention_days = pitr_retention_days
    @storage_autoscaling = storage_autoscaling
    @storage_autoscaling_threshold_percent = storage_autoscaling_threshold_percent
    @storage_autoscaling_max_gb = storage_autoscaling_max_gb
    @maintenance_window_day = maintenance_window_day
    @maintenance_window_hour_utc = maintenance_window_hour_utc
    @metrics_enabled = metrics_enabled
    @sql_api_enabled = sql_api_enabled
    @sql_api_allowed_statements = sql_api_allowed_statements
    @sql_api_max_rows = sql_api_max_rows
    @sql_api_max_bytes = sql_api_max_bytes
    @sql_api_timeout_seconds = sql_api_timeout_seconds
    @error = error
end

Instance Attribute Details

#apiObject (readonly)

Returns the value of attribute api.



11
12
13
# File 'lib/appwrite/models/dedicated_database.rb', line 11

def api
  @api
end

#backendObject (readonly)

Returns the value of attribute backend.



15
16
17
# File 'lib/appwrite/models/dedicated_database.rb', line 15

def backend
  @backend
end

#backup_enabledObject (readonly)

Returns the value of attribute backup_enabled.



40
41
42
# File 'lib/appwrite/models/dedicated_database.rb', line 40

def backup_enabled
  @backup_enabled
end

#connection_passwordObject (readonly)

Returns the value of attribute connection_password.



19
20
21
# File 'lib/appwrite/models/dedicated_database.rb', line 19

def connection_password
  @connection_password
end

#connection_portObject (readonly)

Returns the value of attribute connection_port.



17
18
19
# File 'lib/appwrite/models/dedicated_database.rb', line 17

def connection_port
  @connection_port
end

#connection_stringObject (readonly)

Returns the value of attribute connection_string.



20
21
22
# File 'lib/appwrite/models/dedicated_database.rb', line 20

def connection_string
  @connection_string
end

#connection_userObject (readonly)

Returns the value of attribute connection_user.



18
19
20
# File 'lib/appwrite/models/dedicated_database.rb', line 18

def connection_user
  @connection_user
end

#container_statusObject (readonly)

Returns the value of attribute container_status.



23
24
25
# File 'lib/appwrite/models/dedicated_database.rb', line 23

def container_status
  @container_status
end

#cpuObject (readonly)

Returns the value of attribute cpu.



28
29
30
# File 'lib/appwrite/models/dedicated_database.rb', line 28

def cpu
  @cpu
end

#created_atObject (readonly)

Returns the value of attribute created_at.



7
8
9
# File 'lib/appwrite/models/dedicated_database.rb', line 7

def created_at
  @created_at
end

#cross_region_replicasObject (readonly)

Returns the value of attribute cross_region_replicas.



36
37
38
# File 'lib/appwrite/models/dedicated_database.rb', line 36

def cross_region_replicas
  @cross_region_replicas
end

#engineObject (readonly)

Returns the value of attribute engine.



12
13
14
# File 'lib/appwrite/models/dedicated_database.rb', line 12

def engine
  @engine
end

#errorObject (readonly)

Returns the value of attribute error.



54
55
56
# File 'lib/appwrite/models/dedicated_database.rb', line 54

def error
  @error
end

#hostnameObject (readonly)

Returns the value of attribute hostname.



16
17
18
# File 'lib/appwrite/models/dedicated_database.rb', line 16

def hostname
  @hostname
end

#idObject (readonly)

Returns the value of attribute id.



6
7
8
# File 'lib/appwrite/models/dedicated_database.rb', line 6

def id
  @id
end

#idle_timeout_minutesObject (readonly)

Returns the value of attribute idle_timeout_minutes.



27
28
29
# File 'lib/appwrite/models/dedicated_database.rb', line 27

def idle_timeout_minutes
  @idle_timeout_minutes
end

#idle_untilObject (readonly)

Returns the value of attribute idle_until.



25
26
27
# File 'lib/appwrite/models/dedicated_database.rb', line 25

def idle_until
  @idle_until
end

#last_accessed_atObject (readonly)

Returns the value of attribute last_accessed_at.



24
25
26
# File 'lib/appwrite/models/dedicated_database.rb', line 24

def last_accessed_at
  @last_accessed_at
end

#lifecycle_stateObject (readonly)

Returns the value of attribute lifecycle_state.



26
27
28
# File 'lib/appwrite/models/dedicated_database.rb', line 26

def lifecycle_state
  @lifecycle_state
end

#maintenance_window_dayObject (readonly)

Returns the value of attribute maintenance_window_day.



46
47
48
# File 'lib/appwrite/models/dedicated_database.rb', line 46

def maintenance_window_day
  @maintenance_window_day
end

#maintenance_window_hour_utcObject (readonly)

Returns the value of attribute maintenance_window_hour_utc.



47
48
49
# File 'lib/appwrite/models/dedicated_database.rb', line 47

def maintenance_window_hour_utc
  @maintenance_window_hour_utc
end

#memoryObject (readonly)

Returns the value of attribute memory.



29
30
31
# File 'lib/appwrite/models/dedicated_database.rb', line 29

def memory
  @memory
end

#metrics_enabledObject (readonly)

Returns the value of attribute metrics_enabled.



48
49
50
# File 'lib/appwrite/models/dedicated_database.rb', line 48

def metrics_enabled
  @metrics_enabled
end

#nameObject (readonly)

Returns the value of attribute name.



10
11
12
# File 'lib/appwrite/models/dedicated_database.rb', line 10

def name
  @name
end

#network_idle_timeout_secondsObject (readonly)

Returns the value of attribute network_idle_timeout_seconds.



38
39
40
# File 'lib/appwrite/models/dedicated_database.rb', line 38

def network_idle_timeout_seconds
  @network_idle_timeout_seconds
end

#network_ip_allowlistObject (readonly)

Returns the value of attribute network_ip_allowlist.



39
40
41
# File 'lib/appwrite/models/dedicated_database.rb', line 39

def network_ip_allowlist
  @network_ip_allowlist
end

#network_max_connectionsObject (readonly)

Returns the value of attribute network_max_connections.



37
38
39
# File 'lib/appwrite/models/dedicated_database.rb', line 37

def network_max_connections
  @network_max_connections
end

#node_poolObject (readonly)

Returns the value of attribute node_pool.



33
34
35
# File 'lib/appwrite/models/dedicated_database.rb', line 33

def node_pool
  @node_pool
end

#pitrObject (readonly)

Returns the value of attribute pitr.



41
42
43
# File 'lib/appwrite/models/dedicated_database.rb', line 41

def pitr
  @pitr
end

#pitr_retention_daysObject (readonly)

Returns the value of attribute pitr_retention_days.



42
43
44
# File 'lib/appwrite/models/dedicated_database.rb', line 42

def pitr_retention_days
  @pitr_retention_days
end

#project_idObject (readonly)

Returns the value of attribute project_id.



9
10
11
# File 'lib/appwrite/models/dedicated_database.rb', line 9

def project_id
  @project_id
end

#replicasObject (readonly)

Returns the value of attribute replicas.



34
35
36
# File 'lib/appwrite/models/dedicated_database.rb', line 34

def replicas
  @replicas
end

#specificationObject (readonly)

Returns the value of attribute specification.



14
15
16
# File 'lib/appwrite/models/dedicated_database.rb', line 14

def specification
  @specification
end

#sql_api_allowed_statementsObject (readonly)

Returns the value of attribute sql_api_allowed_statements.



50
51
52
# File 'lib/appwrite/models/dedicated_database.rb', line 50

def sql_api_allowed_statements
  @sql_api_allowed_statements
end

#sql_api_enabledObject (readonly)

Returns the value of attribute sql_api_enabled.



49
50
51
# File 'lib/appwrite/models/dedicated_database.rb', line 49

def sql_api_enabled
  @sql_api_enabled
end

#sql_api_max_bytesObject (readonly)

Returns the value of attribute sql_api_max_bytes.



52
53
54
# File 'lib/appwrite/models/dedicated_database.rb', line 52

def sql_api_max_bytes
  @sql_api_max_bytes
end

#sql_api_max_rowsObject (readonly)

Returns the value of attribute sql_api_max_rows.



51
52
53
# File 'lib/appwrite/models/dedicated_database.rb', line 51

def sql_api_max_rows
  @sql_api_max_rows
end

#sql_api_timeout_secondsObject (readonly)

Returns the value of attribute sql_api_timeout_seconds.



53
54
55
# File 'lib/appwrite/models/dedicated_database.rb', line 53

def sql_api_timeout_seconds
  @sql_api_timeout_seconds
end

#sslObject (readonly)

Returns the value of attribute ssl.



21
22
23
# File 'lib/appwrite/models/dedicated_database.rb', line 21

def ssl
  @ssl
end

#statusObject (readonly)

Returns the value of attribute status.



22
23
24
# File 'lib/appwrite/models/dedicated_database.rb', line 22

def status
  @status
end

#storageObject (readonly)

Returns the value of attribute storage.



30
31
32
# File 'lib/appwrite/models/dedicated_database.rb', line 30

def storage
  @storage
end

#storage_autoscalingObject (readonly)

Returns the value of attribute storage_autoscaling.



43
44
45
# File 'lib/appwrite/models/dedicated_database.rb', line 43

def storage_autoscaling
  @storage_autoscaling
end

#storage_autoscaling_max_gbObject (readonly)

Returns the value of attribute storage_autoscaling_max_gb.



45
46
47
# File 'lib/appwrite/models/dedicated_database.rb', line 45

def storage_autoscaling_max_gb
  @storage_autoscaling_max_gb
end

#storage_autoscaling_threshold_percentObject (readonly)

Returns the value of attribute storage_autoscaling_threshold_percent.



44
45
46
# File 'lib/appwrite/models/dedicated_database.rb', line 44

def storage_autoscaling_threshold_percent
  @storage_autoscaling_threshold_percent
end

#storage_classObject (readonly)

Returns the value of attribute storage_class.



31
32
33
# File 'lib/appwrite/models/dedicated_database.rb', line 31

def storage_class
  @storage_class
end

#storage_max_gbObject (readonly)

Returns the value of attribute storage_max_gb.



32
33
34
# File 'lib/appwrite/models/dedicated_database.rb', line 32

def storage_max_gb
  @storage_max_gb
end

#sync_modeObject (readonly)

Returns the value of attribute sync_mode.



35
36
37
# File 'lib/appwrite/models/dedicated_database.rb', line 35

def sync_mode
  @sync_mode
end

#updated_atObject (readonly)

Returns the value of attribute updated_at.



8
9
10
# File 'lib/appwrite/models/dedicated_database.rb', line 8

def updated_at
  @updated_at
end

#versionObject (readonly)

Returns the value of attribute version.



13
14
15
# File 'lib/appwrite/models/dedicated_database.rb', line 13

def version
  @version
end

Class Method Details

.from(map:) ⇒ Object



158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
# File 'lib/appwrite/models/dedicated_database.rb', line 158

def self.from(map:)
    DedicatedDatabase.new(
        id: map["$id"],
        created_at: map["$createdAt"],
        updated_at: map["$updatedAt"],
        project_id: map["projectId"],
        name: map["name"],
        api: map["api"],
        engine: map["engine"],
        version: map["version"],
        specification: map["specification"],
        backend: map["backend"],
        hostname: map["hostname"],
        connection_port: map["connectionPort"],
        connection_user: map["connectionUser"],
        connection_password: map["connectionPassword"],
        connection_string: map["connectionString"],
        ssl: map["ssl"],
        status: map["status"],
        container_status: map["containerStatus"],
        last_accessed_at: map["lastAccessedAt"],
        idle_until: map["idleUntil"],
        lifecycle_state: map["lifecycleState"],
        idle_timeout_minutes: map["idleTimeoutMinutes"],
        cpu: map["cpu"],
        memory: map["memory"],
        storage: map["storage"],
        storage_class: map["storageClass"],
        storage_max_gb: map["storageMaxGb"],
        node_pool: map["nodePool"],
        replicas: map["replicas"],
        sync_mode: map["syncMode"],
        cross_region_replicas: map["crossRegionReplicas"],
        network_max_connections: map["networkMaxConnections"],
        network_idle_timeout_seconds: map["networkIdleTimeoutSeconds"],
        network_ip_allowlist: map["networkIPAllowlist"],
        backup_enabled: map["backupEnabled"],
        pitr: map["pitr"],
        pitr_retention_days: map["pitrRetentionDays"],
        storage_autoscaling: map["storageAutoscaling"],
        storage_autoscaling_threshold_percent: map["storageAutoscalingThresholdPercent"],
        storage_autoscaling_max_gb: map["storageAutoscalingMaxGb"],
        maintenance_window_day: map["maintenanceWindowDay"],
        maintenance_window_hour_utc: map["maintenanceWindowHourUtc"],
        metrics_enabled: map["metricsEnabled"],
        sql_api_enabled: map["sqlApiEnabled"],
        sql_api_allowed_statements: map["sqlApiAllowedStatements"],
        sql_api_max_rows: map["sqlApiMaxRows"],
        sql_api_max_bytes: map["sqlApiMaxBytes"],
        sql_api_timeout_seconds: map["sqlApiTimeoutSeconds"],
        error: map["error"]
    )
end

Instance Method Details

#to_mapObject



212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
# File 'lib/appwrite/models/dedicated_database.rb', line 212

def to_map
    {
        "$id": @id,
        "$createdAt": @created_at,
        "$updatedAt": @updated_at,
        "projectId": @project_id,
        "name": @name,
        "api": @api,
        "engine": @engine,
        "version": @version,
        "specification": @specification,
        "backend": @backend,
        "hostname": @hostname,
        "connectionPort": @connection_port,
        "connectionUser": @connection_user,
        "connectionPassword": @connection_password,
        "connectionString": @connection_string,
        "ssl": @ssl,
        "status": @status,
        "containerStatus": @container_status,
        "lastAccessedAt": @last_accessed_at,
        "idleUntil": @idle_until,
        "lifecycleState": @lifecycle_state,
        "idleTimeoutMinutes": @idle_timeout_minutes,
        "cpu": @cpu,
        "memory": @memory,
        "storage": @storage,
        "storageClass": @storage_class,
        "storageMaxGb": @storage_max_gb,
        "nodePool": @node_pool,
        "replicas": @replicas,
        "syncMode": @sync_mode,
        "crossRegionReplicas": @cross_region_replicas,
        "networkMaxConnections": @network_max_connections,
        "networkIdleTimeoutSeconds": @network_idle_timeout_seconds,
        "networkIPAllowlist": @network_ip_allowlist,
        "backupEnabled": @backup_enabled,
        "pitr": @pitr,
        "pitrRetentionDays": @pitr_retention_days,
        "storageAutoscaling": @storage_autoscaling,
        "storageAutoscalingThresholdPercent": @storage_autoscaling_threshold_percent,
        "storageAutoscalingMaxGb": @storage_autoscaling_max_gb,
        "maintenanceWindowDay": @maintenance_window_day,
        "maintenanceWindowHourUtc": @maintenance_window_hour_utc,
        "metricsEnabled": @metrics_enabled,
        "sqlApiEnabled": @sql_api_enabled,
        "sqlApiAllowedStatements": @sql_api_allowed_statements,
        "sqlApiMaxRows": @sql_api_max_rows,
        "sqlApiMaxBytes": @sql_api_max_bytes,
        "sqlApiTimeoutSeconds": @sql_api_timeout_seconds,
        "error": @error
    }
end