-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ver 90388 save restore point before upgrade #920
base: main
Are you sure you want to change the base?
Changes from all commits
4efd5ef
3b2b403
2f46aa4
559be18
d2f703a
5ea9d38
2cb92d7
c2539a1
680bef4
60d0191
03567a8
77c5440
c1366d0
7e5bd1d
135c1bf
d1bf37e
6bc5e0c
4306123
a7c70c1
703726e
a755c2c
7aa4bf7
10690d8
c01016e
550fed6
3e44008
1a65916
e0e943f
56358e7
2e1a214
8a6e7ab
4d4b863
54a2782
5be8b72
08a8a49
307c187
c518db9
693dc3a
1a44346
32c6e19
b1db019
012afec
c43de68
d3a8e9f
923003d
1233fa9
5663695
fb93c3b
2858552
6bc209f
372fc09
30caca1
73b4c6e
83dce05
52bae88
94e8de2
668189c
39a3086
22e62c5
44a21e1
cafc23b
0645f2a
709b161
8038adf
c88de60
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -107,6 +107,8 @@ | |
|
||
// Functions to perform when the image changes. Order matters. | ||
funcs := []func(context.Context) (ctrl.Result, error){ | ||
// Save restore point before start upgrade | ||
o.saveRestorePoint, | ||
// Initiate an upgrade by setting condition and event recording | ||
o.startUpgrade, | ||
o.logEventIfThisUpgradeWasNotChosen, | ||
|
@@ -151,6 +153,15 @@ | |
return ctrl.Result{}, o.Manager.logUpgradeSucceeded(sandbox) | ||
} | ||
|
||
func (o *OfflineUpgradeReconciler) saveRestorePoint(ctx context.Context) (ctrl.Result, error) { | ||
actor := MakeSaveRestorePointReconciler(o.Rec, o.Vdb, o.Log, o.PFacts, o.Dispatcher, o.Rec.GetClient()) | ||
Check failure on line 157 in pkg/controllers/vdb/offlineupgrade_reconciler.go
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @roypaulin is this the proper way to call the other Reconciler and its method? |
||
saveRestoreRec := actor.(*SaveRestorePoint) | ||
|
||
hostIP, ok := pfacts.FindFirstUpPodIP(true, "") | ||
Check failure on line 160 in pkg/controllers/vdb/offlineupgrade_reconciler.go
|
||
saveRestoreRec.runSaveRestorePointVclusterAPI(ctx, hostIP, archive, pf.sandbox) | ||
Check failure on line 161 in pkg/controllers/vdb/offlineupgrade_reconciler.go
|
||
return o.Manager.startUpgrade(ctx, o.PFacts.GetSandboxName()) | ||
} | ||
|
||
func (o *OfflineUpgradeReconciler) startUpgrade(ctx context.Context) (ctrl.Result, error) { | ||
return o.Manager.startUpgrade(ctx, o.PFacts.GetSandboxName()) | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@roypaulin For offline and read-only upgrade, we want the job "o.saveRestorePoint" before "startUpgrade", right? or other orders