Skip to content

Commit

Permalink
Controller reconciliation rework - part 2 (ServiceBinding) (openshift…
Browse files Browse the repository at this point in the history
…#1819)

* Controller reconciliation rework - part 2 (ServiceBinding)

* Exit the reconciliation loop iteration after each update to ServiceBinding

* Validate KubeClient and BrokerClient actions after each invocation of reconcileServiceBinding()

* Reduce code duplication in controller_binding_test.go
  • Loading branch information
luksa authored and staebler committed Mar 9, 2018
1 parent c606560 commit 6426c98
Show file tree
Hide file tree
Showing 2 changed files with 328 additions and 262 deletions.
4 changes: 4 additions & 0 deletions pkg/controller/controller_binding.go
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,8 @@ func (c *controller) reconcileServiceBindingAdd(binding *v1beta1.ServiceBinding)
// over with a fresh view of the binding.
return err
}
// recordStartOfServiceBindingOperation has updated the binding, so we need to continue in the next iteration
return nil
}

response, err := brokerClient.Bind(request)
Expand Down Expand Up @@ -342,6 +344,8 @@ func (c *controller) reconcileServiceBindingDelete(binding *v1beta1.ServiceBindi
// over with a fresh view of the binding.
return err
}
// recordStartOfServiceBindingOperation has updated the binding, so we need to continue in the next iteration
return nil
}
}

Expand Down
Loading

0 comments on commit 6426c98

Please sign in to comment.