Quellcode durchsuchen

Before Test Code

scotty.scott vor 2 Jahren
Ursprung
Commit
f365d0b859

+ 0 - 9
config/crd/bases/app.demo.kakao.com_bluegreens.yaml

@@ -13757,20 +13757,11 @@ spec:
           status:
             description: BlueGreenStatus defines the observed state of BlueGreen
             properties:
-              blueReady:
-                format: int32
-                type: integer
-              greenReady:
-                format: int32
-                type: integer
               routeTo:
                 enum:
                 - Blue
                 - Green
                 type: string
-            required:
-            - blueReady
-            - greenReady
             type: object
         type: object
     served: true

+ 2 - 1
controllers/bluegreen_controller.go

@@ -46,7 +46,8 @@ type BlueGreenReconciler struct {
 
 func (r *BlueGreenReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error) {
 	log := log.FromContext(ctx)
-	log.Info("event", "name", req.Name, "namespace", req.Namespace)
+	log.Info("Reconcile Start", "name", req.Name, "namespace", req.Namespace)
+	defer log.Info("Reconcile Finished", "name", req.Name, "namespace", req.Namespace)
 
 	bluegreen := new(v1.BlueGreen)
 	if err := r.Client.Get(ctx, req.NamespacedName, bluegreen); err != nil {