blob: 14ef7f5ced418b112a5a061781dd0005edab3b90 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
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
|
syntax = "proto3";
package yandex.cloud.mdb.postgresql.v1;
import "google/api/annotations.proto";
import "yandex/cloud/validation.proto";
import "yandex/cloud/api/operation.proto";
import "yandex/cloud/operation/operation.proto";
import "yandex/cloud/mdb/postgresql/v1/backup.proto";
option go_package = "github.com/yandex-cloud/go-genproto/yandex/cloud/mdb/postgresql/v1;postgresql";
option java_package = "yandex.cloud.api.mdb.postgresql.v1";
// A set of methods for managing PostgreSQL Backup resources.
service BackupService {
// Returns the specified PostgreSQL Backup resource.
//
// To get the list of available PostgreSQL Backup resources, make a [List] request.
rpc Get (GetBackupRequest) returns (Backup) {
option (google.api.http) = { get: "/managed-postgresql/v1/backups/{backup_id}" };
}
// Retrieves the list of Backup resources available for the specified folder.
rpc List (ListBackupsRequest) returns (ListBackupsResponse) {
option (google.api.http) = { get: "/managed-postgresql/v1/backups" };
}
// Deletes the specified PostgreSQL cluster backup.
rpc Delete (DeleteBackupRequest) returns (operation.Operation) {
option (google.api.http) = { delete: "/managed-postgresql/v1/backups/{backup_id}" };
option (yandex.cloud.api.operation) = {
metadata: "DeleteBackupMetadata"
response: "google.protobuf.Empty"
};
}
}
message GetBackupRequest {
// ID of the backup to return information about.
// To get the backup ID, use a [ClusterService.ListBackups] request.
string backup_id = 1 [(required) = true];
}
message ListBackupsRequest {
// ID of the folder to list backups in.
// To get the folder ID, use a [yandex.cloud.resourcemanager.v1.FolderService.List] request.
string folder_id = 1 [(required) = true, (length) = "<=50"];
// The maximum number of results per page to return. If the number of available
// results is larger than [page_size], the service returns a [ListBackupsResponse.next_page_token]
// that can be used to get the next page of results in subsequent list requests.
int64 page_size = 2 [(value) = "<=1000"];
// Page token. To get the next page of results, Set [page_token] to the [ListBackupsResponse.next_page_token]
// returned by the previous list request.
string page_token = 3 [(length) = "<=100"];
}
message ListBackupsResponse {
// List of PostgreSQL Backup resources.
repeated Backup backups = 1;
// This token allows you to get the next page of results for list requests. If the number of results
// is larger than [ListBackupsRequest.page_size], use the [next_page_token] as the value
// for the [ListBackupsRequest.page_token] parameter in the next list request. Each subsequent
// list request will have its own [next_page_token] to continue paging through the results.
string next_page_token = 2 [(length) = "<=100"];
}
message DeleteBackupRequest {
// Required. ID of the backup to delete.
string backup_id = 1 [(required) = true];
}
message DeleteBackupMetadata {
// Required. ID of the PostgreSQL backup that is currently being deleted.
string backup_id = 1;
// ID of the cluster which backup belonged to.
string cluster_id = 2;
}
|