Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions docs/protocol.md
Original file line number Diff line number Diff line change
Expand Up @@ -1505,6 +1505,7 @@ through the kube-api server.
| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| cluster_definition | [bytes](#bytes) | | This field is REQUIRED. Value of this field is the JSON serialization of the Cluster. |
| check_empty_wal_archive | [bool](#bool) | optional | This field is OPTIONAL. The operator always sets it, to convey its decision on whether the plugin should verify that the backup destination is not already in use by a different cluster or timeline before restoring (protection against WAL/timeline divergence). If unset, the request comes from an operator that predates this field, and the plugin is free to handle that case as it sees fit. |



Expand Down Expand Up @@ -1604,6 +1605,7 @@ Intentionally empty.
| cluster_definition | [bytes](#bytes) | | This field is REQUIRED. Value of this field is the JSON serialization of the Cluster corresponding to the Pod being applied |
| source_file_name | [string](#string) | | This field is REQUIRED. Value of this field is the full path of the WAL file that should be archived |
| parameters | [WALArchiveRequest.ParametersEntry](#cnpgi-wal-v1-WALArchiveRequest-ParametersEntry) | repeated | This field is OPTIONAL. Values are opaque. |
| check_empty_wal_archive | [bool](#bool) | optional | This field is OPTIONAL. The operator always sets it, to convey its decision on whether the plugin should verify the WAL archive destination is empty before this upload. If unset, the request comes from an operator that predates this field, and the plugin is free to handle that case as it sees fit. |



Expand Down
25 changes: 21 additions & 4 deletions pkg/restore/job/restore_job.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

28 changes: 22 additions & 6 deletions pkg/wal/wal.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions proto/restore_job.proto
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,14 @@ message RestoreRequest {
// This field is REQUIRED. Value of this field is the JSON
// serialization of the Cluster.
bytes cluster_definition = 1;

// This field is OPTIONAL. The operator always sets it, to convey its
// decision on whether the plugin should verify that the backup
// destination is not already in use by a different cluster or timeline
// before restoring (protection against WAL/timeline divergence). If
// unset, the request comes from an operator that predates this field,
// and the plugin is free to handle that case as it sees fit.
optional bool check_empty_wal_archive = 2;
}

message RestoreResponse {
Expand Down
7 changes: 7 additions & 0 deletions proto/wal.proto
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,13 @@ message WALArchiveRequest {

// This field is OPTIONAL. Values are opaque.
map<string, string> parameters = 3;

// This field is OPTIONAL. The operator always sets it, to convey its
// decision on whether the plugin should verify the WAL archive
// destination is empty before this upload. If unset, the request comes
// from an operator that predates this field, and the plugin is free to
// handle that case as it sees fit.
optional bool check_empty_wal_archive = 4;
}

message WALArchiveResult {
Expand Down