-
-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #17 from adyanth/goreport-enhancement
Go Report Card enhancement
- Loading branch information
Showing
5 changed files
with
88 additions
and
64 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -203,6 +203,11 @@ func (r *ServiceReconciler) initStruct(ctx context.Context, service *corev1.Serv | |
//+kubebuilder:rbac:groups=apps,resources=deployments,verbs=get;update;patch | ||
//+kubebuilder:rbac:groups="",resources=events,verbs=create;patch | ||
|
||
// Reconcile is part of the main kubernetes reconciliation loop which aims to | ||
// move the current state of the cluster closer to the desired state. | ||
// | ||
// For more details, check Reconcile and its Result here: | ||
// - https://pkg.go.dev/sigs.k8s.io/[email protected]/pkg/reconcile | ||
func (r *ServiceReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) { | ||
r.log = ctrllog.FromContext(ctx) | ||
|
||
|
@@ -238,10 +243,10 @@ func (r *ServiceReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ct | |
// Check if Service is marked for deletion | ||
if r.service.GetDeletionTimestamp() != nil { | ||
return ctrl.Result{}, r.deletionLogic() | ||
} else { | ||
if err := r.creationLogic(); err != nil { | ||
return ctrl.Result{}, err | ||
} | ||
} | ||
|
||
if err := r.creationLogic(); err != nil { | ||
return ctrl.Result{}, err | ||
} | ||
|
||
// Configure ConfigMap | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters