Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Reduce CPU and Memory usage
Signed-off-by: Daniel Fan <[email protected]>
  • Loading branch information
Daniel-Fan committed Jan 11, 2024
commit 192f9ba549dda84607e964b845550810069528e3
4 changes: 2 additions & 2 deletions controllers/operator/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func NewODLMOperator(mgr manager.Manager, name string) *ODLMOperator {
Config: mgr.GetConfig(),
Recorder: mgr.GetEventRecorderFor(name),
Scheme: mgr.GetScheme(),
MaxConcurrentReconciles: 10,
MaxConcurrentReconciles: 3,
}
}

Expand Down Expand Up @@ -366,7 +366,7 @@ func (m *ODLMOperator) GetClusterServiceVersion(ctx context.Context, sub *olmv1a
Name: csvName,
Namespace: csvNamespace,
}
if err := m.Client.Get(ctx, csvKey, csv); err != nil {
if err := m.Reader.Get(ctx, csvKey, csv); err != nil {
if apierrors.IsNotFound(err) {
klog.V(3).Infof("ClusterServiceVersion %s is not ready. Will check it when it is stable", sub.Name)
return nil, nil
Expand Down