chore: add auto backup workspace setting

This commit is contained in:
steven
2023-09-02 14:17:23 +08:00
parent b8f31cfd25
commit 7c4ccbef3f
5 changed files with 575 additions and 0 deletions

View File

@ -0,0 +1,30 @@
syntax = "proto3";
package slash.store;
option go_package = "gen/store";
message WorkspaceSetting {
WorkspaceSettingKey key = 1;
oneof value {
AutoBackupWorkspaceSetting auto_backup = 2;
}
}
enum WorkspaceSettingKey {
WORKSPACE_SETTING_KEY_UNSPECIFIED = 0;
WORKSPACE_SETTING_AUTO_BACKUP = 1;
}
message AutoBackupWorkspaceSetting {
// Whether auto backup is enabled.
bool enabled = 1;
// The cron expression for auto backup.
// For example, "0 0 0 * * *" means backup at 00:00:00 every day.
// See https://en.wikipedia.org/wiki/Cron for more details.
string cron_expression = 2;
// The maximum number of backups to keep.
int32 max_keep = 3;
}