Skip to content

Commit 535efca

Browse files
authored
Prepare for release v0.16.0 (#1394)
ProductLine: Stash Release: v2021.10.11 Release-tracker: stashed/CHANGELOG#41 Signed-off-by: 1gtm <1gtm@appscode.com>
1 parent 7c26c7d commit 535efca

File tree

5 files changed

+26
-4
lines changed

5 files changed

+26
-4
lines changed

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ require (
4545
kmodules.xyz/openshift v0.0.0-20210618001443-f2507caa512f
4646
kmodules.xyz/prober v0.0.0-20210618020259-5836fb959027
4747
kmodules.xyz/webhook-runtime v0.0.0-20210928141616-7f73c2ab318a
48-
stash.appscode.dev/apimachinery v0.15.1-0.20211008114243-3ddabb572a0a
48+
stash.appscode.dev/apimachinery v0.16.0
4949
)
5050

5151
replace bitbucket.org/ww/goautoneg => gomodules.xyz/goautoneg v0.0.0-20120707110453-a547fc61f48d

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1263,5 +1263,5 @@ sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o=
12631263
sigs.k8s.io/yaml v1.2.0 h1:kr/MCeFWJWTwyaHoR9c8EjH9OumOmoF9YGiZd7lFm/Q=
12641264
sigs.k8s.io/yaml v1.2.0/go.mod h1:yfXDCHCao9+ENCvLSE62v9VSji2MKu5jeNfTrofGhJc=
12651265
sourcegraph.com/sourcegraph/appdash v0.0.0-20190731080439-ebfcffb1b5c0/go.mod h1:hI742Nqp5OhwiqlzhgfbWU4mW4yO10fP+LoT9WOswdU=
1266-
stash.appscode.dev/apimachinery v0.15.1-0.20211008114243-3ddabb572a0a h1:MYMUAvHKN+UFtB0HDX+oZjpfFQdetDchiEe3DsFqtXg=
1267-
stash.appscode.dev/apimachinery v0.15.1-0.20211008114243-3ddabb572a0a/go.mod h1:owQaNhtUMh6s727PX9dGIoLlqblMvMOtYLF2jy9CUek=
1266+
stash.appscode.dev/apimachinery v0.16.0 h1:6mvmPatv9nR5Wc+PCt3Cg9R7WRJRqhy2yLu2b/HmXhA=
1267+
stash.appscode.dev/apimachinery v0.16.0/go.mod h1:unpV/YyHVECNrAdFjFg/SetmPeUjfvc2+P8cnGjih/U=

vendor/modules.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1482,7 +1482,7 @@ sigs.k8s.io/structured-merge-diff/v4/typed
14821482
sigs.k8s.io/structured-merge-diff/v4/value
14831483
# sigs.k8s.io/yaml v1.2.0
14841484
sigs.k8s.io/yaml
1485-
# stash.appscode.dev/apimachinery v0.15.1-0.20211008114243-3ddabb572a0a
1485+
# stash.appscode.dev/apimachinery v0.16.0
14861486
## explicit
14871487
stash.appscode.dev/apimachinery/apis
14881488
stash.appscode.dev/apimachinery/apis/repositories

vendor/stash.appscode.dev/apimachinery/apis/constants.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,10 @@ const (
204204
StashInitContainerInjected = "StashInitContainerInjected"
205205
// RestoreJobCreated indicates whether the restore job was created
206206
RestoreJobCreated = "RestoreJobCreated"
207+
// RestoreCompleted condition indicates whether the restore process has been completed or not.
208+
// This condition is particularly helpful when the restore addon require some additional operations to perform
209+
// before marking the RestoreSession Succeeded/Failed.
210+
RestoreCompleted = "RestoreCompleted"
207211

208212
// GlobalPreBackupHookSucceeded indicates whether the global PreBackupHook was executed successfully or not
209213
GlobalPreBackupHookSucceeded = "GlobalPreBackupHookSucceeded"

vendor/stash.appscode.dev/apimachinery/pkg/conditions/restore.go

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,3 +106,21 @@ func SetInitContainerInjectedConditionToFalse(inv invoker.RestoreInvoker, tref a
106106
Message: fmt.Sprintf("Failed to inject Stash init-container. Reason: %v", err.Error()),
107107
})
108108
}
109+
110+
func SetRestoreCompletedConditionToTrue(inv invoker.RestoreInvoker, tref api_v1beta1.TargetRef, msg string) error {
111+
return inv.SetCondition(&tref, kmapi.Condition{
112+
Type: apis.RestoreCompleted,
113+
Status: core.ConditionTrue,
114+
Reason: "PostRestoreTasksExecuted",
115+
Message: msg,
116+
})
117+
}
118+
119+
func SetRestoreCompletedConditionToFalse(inv invoker.RestoreInvoker, tref api_v1beta1.TargetRef, msg string) error {
120+
return inv.SetCondition(&tref, kmapi.Condition{
121+
Type: apis.RestoreCompleted,
122+
Status: core.ConditionFalse,
123+
Reason: "PostRestoreTasksNotExecuted",
124+
Message: msg,
125+
})
126+
}

0 commit comments

Comments
 (0)