@@ -798,11 +798,6 @@ func (a *Operator) copyToNamespace(prototype *v1alpha1.ClusterServiceVersion, ns
798
798
return nil , fmt .Errorf ("bug: can not copy to active namespace %v" , nsFrom )
799
799
}
800
800
801
- a .logger .WithFields (logrus.Fields {
802
- "nsFrom" : nsFrom ,
803
- "nsTo" : nsTo ,
804
- }).Info ("copyToNamespace" )
805
-
806
801
prototype .Namespace = nsTo
807
802
prototype .ResourceVersion = ""
808
803
prototype .UID = ""
@@ -840,6 +835,10 @@ func (a *Operator) copyToNamespace(prototype *v1alpha1.ClusterServiceVersion, ns
840
835
if updated , err = a .client .OperatorsV1alpha1 ().ClusterServiceVersions (nsTo ).Update (context .TODO (), prototype , metav1.UpdateOptions {}); err != nil {
841
836
return nil , fmt .Errorf ("failed to update: %w" , err )
842
837
}
838
+ a .logger .WithFields (logrus.Fields {
839
+ "nsFrom" : nsFrom ,
840
+ "nsTo" : nsTo ,
841
+ }).Info ("copyToNamespace: updated Metadata+Spec" )
843
842
} else {
844
843
// Avoid mutating cached copied CSV.
845
844
updated = prototype
@@ -850,6 +849,10 @@ func (a *Operator) copyToNamespace(prototype *v1alpha1.ClusterServiceVersion, ns
850
849
if _ , err = a .client .OperatorsV1alpha1 ().ClusterServiceVersions (nsTo ).UpdateStatus (context .TODO (), updated , metav1.UpdateOptions {}); err != nil {
851
850
return nil , fmt .Errorf ("failed to update status: %w" , err )
852
851
}
852
+ a .logger .WithFields (logrus.Fields {
853
+ "nsFrom" : nsFrom ,
854
+ "nsTo" : nsTo ,
855
+ }).Info ("copyToNamespace: updated Status" )
853
856
}
854
857
return & v1alpha1.ClusterServiceVersion {
855
858
ObjectMeta : metav1.ObjectMeta {
0 commit comments