This is an automated email from the ASF dual-hosted git repository.

squakez pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-k.git

commit 17b0157382635ff200bf61b3efc6988fca5b23cf
Author: chaojixinren <[email protected]>
AuthorDate: Fri Apr 17 15:39:54 2026 +0800

    chore(controller/integration): rename nonSyntheticActions to baseActions
---
 .../integration/integration_controller.go          | 25 +++++++++++-----------
 .../integration/integration_controller_test.go     |  8 +++----
 2 files changed, 17 insertions(+), 16 deletions(-)

diff --git a/pkg/controller/integration/integration_controller.go 
b/pkg/controller/integration/integration_controller.go
index 1b415efe1..07db00747 100644
--- a/pkg/controller/integration/integration_controller.go
+++ b/pkg/controller/integration/integration_controller.go
@@ -74,20 +74,21 @@ func Add(ctx context.Context, mgr manager.Manager, c 
client.Client) error {
 }
 
 func newReconciler(mgr manager.Manager, c client.Client) reconcile.Reconciler {
-       baseActions := []Action{
+       base := []Action{
                NewPlatformSetupAction(),
                NewInitializeAction(),
                NewBuildAction(),
                newBuildKitAction(),
                NewBuildCompleteAction(),
        }
+
        return monitoring.NewInstrumentedReconciler(
                &reconcileIntegration{
-                       client:              c,
-                       scheme:              mgr.GetScheme(),
-                       recorder:            
mgr.GetEventRecorder("camel-k-integration-controller"),
-                       syntheticActions:    append(append([]Action{}, 
baseActions...), NewMonitorSyntheticAction()),
-                       nonSyntheticActions: append(append([]Action{}, 
baseActions...), NewMonitorAction(), NewMonitorUnknownAction()),
+                       client:           c,
+                       scheme:           mgr.GetScheme(),
+                       recorder:         
mgr.GetEventRecorder("camel-k-integration-controller"),
+                       syntheticActions: append(append([]Action{}, base...), 
NewMonitorSyntheticAction()),
+                       baseActions:      append(append([]Action{}, base...), 
NewMonitorAction(), NewMonitorUnknownAction()),
                },
                schema.GroupVersionKind{
                        Group:   v1.SchemeGroupVersion.Group,
@@ -462,11 +463,11 @@ var _ reconcile.Reconciler = &reconcileIntegration{}
 type reconcileIntegration struct {
        // This client, initialized using mgr.Client() above, is a split client
        // that reads objects from the cache and writes to the API server
-       client              client.Client
-       scheme              *runtime.Scheme
-       recorder            events.EventRecorder
-       syntheticActions    []Action
-       nonSyntheticActions []Action
+       client           client.Client
+       scheme           *runtime.Scheme
+       recorder         events.EventRecorder
+       syntheticActions []Action
+       baseActions      []Action
 }
 
 // Reconcile reads that state of the cluster for an Integration object and 
makes changes based on the state read
@@ -511,7 +512,7 @@ func (r *reconcileIntegration) Reconcile(ctx 
context.Context, request reconcile.
        target := instance.DeepCopy()
        targetLog := rlog.ForIntegration(target)
 
-       actions := r.nonSyntheticActions
+       actions := r.baseActions
        if instance.IsSynthetic() {
                actions = r.syntheticActions
        }
diff --git a/pkg/controller/integration/integration_controller_test.go 
b/pkg/controller/integration/integration_controller_test.go
index 318dfb528..3cee401cb 100644
--- a/pkg/controller/integration/integration_controller_test.go
+++ b/pkg/controller/integration/integration_controller_test.go
@@ -30,7 +30,7 @@ import (
 )
 
 func TestActions(t *testing.T) {
-       baseActions := []Action{
+       base := []Action{
                NewPlatformSetupAction(),
                NewInitializeAction(),
                NewBuildAction(),
@@ -38,12 +38,12 @@ func TestActions(t *testing.T) {
                NewBuildCompleteAction(),
        }
        reconciler := reconcileIntegration{
-               syntheticActions:    append(append([]Action{}, baseActions...), 
NewMonitorSyntheticAction()),
-               nonSyntheticActions: append(append([]Action{}, baseActions...), 
NewMonitorAction(), NewMonitorUnknownAction()),
+               syntheticActions: append(append([]Action{}, base...), 
NewMonitorSyntheticAction()),
+               baseActions:      append(append([]Action{}, base...), 
NewMonitorAction(), NewMonitorUnknownAction()),
        }
 
        t.Run("non-synthetic", func(t *testing.T) {
-               actions := reconciler.nonSyntheticActions
+               actions := reconciler.baseActions
                require.Len(t, actions, 7)
 
                assert.IsType(t, &platformSetupAction{}, actions[0])

Reply via email to