Skip to content

Commit 2a026d3

Browse files
authored
[Bugfix] Fix ActiveFailover upgrade proceure (#620)
1 parent 145d71d commit 2a026d3

File tree

4 files changed

+4
-7
lines changed

4 files changed

+4
-7
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
## [master](https://github.com/arangodb/kube-arangodb/tree/master) (N/A)
44
- Add Operator Namespaced mode (Alpha)
5+
- Fix ActiveFailover Upgrade procedure
56

67
## [1.0.5](https://github.com/arangodb/kube-arangodb/tree/1.0.5) (2020-08-05)
78
- Add Labels and Annotations to ServiceMonitor

pkg/apis/deployment/v1/server_group.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,8 @@ const (
5353
var (
5454
// AllServerGroups contains a constant list of all known server groups
5555
AllServerGroups = []ServerGroup{
56-
ServerGroupSingle,
5756
ServerGroupAgents,
57+
ServerGroupSingle,
5858
ServerGroupDBServers,
5959
ServerGroupCoordinators,
6060
ServerGroupSyncMasters,

pkg/deployment/reconcile/action_wait_for_member_up.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ func (a *actionWaitForMemberUp) checkProgressSingle(ctx context.Context) (bool,
111111
// of a single server as part of an active failover deployment.
112112
func (a *actionWaitForMemberUp) checkProgressSingleInActiveFailover(ctx context.Context) (bool, bool, error) {
113113
log := a.log
114-
c, err := a.actionCtx.GetDatabaseClient(ctx)
114+
c, err := a.actionCtx.GetServerClient(ctx, a.action.Group, a.action.MemberID)
115115
if err != nil {
116116
log.Debug().Err(err).Msg("Failed to create database client")
117117
return false, false, maskAny(err)
@@ -120,10 +120,6 @@ func (a *actionWaitForMemberUp) checkProgressSingleInActiveFailover(ctx context.
120120
log.Debug().Err(err).Msg("Failed to get version")
121121
return false, false, maskAny(err)
122122
}
123-
if _, err := c.Databases(ctx); err != nil {
124-
log.Debug().Err(err).Msg("Failed to get databases")
125-
return false, false, maskAny(err)
126-
}
127123
return true, false, nil
128124
}
129125

pkg/deployment/reconcile/plan_builder_rotate_upgrade.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@ import (
4040
var (
4141
// rotationByAnnotationOrder - Change order of execution - Coordinators and Agents should be executed before DBServer to save time
4242
rotationByAnnotationOrder = []api.ServerGroup{
43-
api.ServerGroupSingle,
4443
api.ServerGroupAgents,
44+
api.ServerGroupSingle,
4545
api.ServerGroupCoordinators,
4646
api.ServerGroupDBServers,
4747
api.ServerGroupSyncMasters,

0 commit comments

Comments
 (0)