Skip to content

Commit

Permalink
chore: change import alias to match the actual import (#345)
Browse files Browse the repository at this point in the history
  • Loading branch information
dushanpantic authored Jul 12, 2024
1 parent 50fe51e commit 5cdaf12
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions pkg/kcp/redisinstance/loadIpRange.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (

types2 "github.com/kyma-project/cloud-manager/pkg/kcp/redisinstance/types"

cloudresourcesv1beta1 "github.com/kyma-project/cloud-manager/api/cloud-control/v1beta1"
cloudcontrolv1beta1 "github.com/kyma-project/cloud-manager/api/cloud-control/v1beta1"
"github.com/kyma-project/cloud-manager/pkg/composed"
apierrors "k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/api/meta"
Expand All @@ -22,7 +22,7 @@ func loadIpRange(ctx context.Context, st composed.State) (error, context.Context
redisInstance := state.ObjAsRedisInstance()
ipRangeName := redisInstance.Spec.IpRange.Name

ipRange := &cloudresourcesv1beta1.IpRange{}
ipRange := &cloudcontrolv1beta1.IpRange{}
err := state.Cluster().K8sClient().Get(ctx, types.NamespacedName{
Namespace: state.Obj().GetNamespace(),
Name: ipRangeName,
Expand All @@ -37,9 +37,9 @@ func loadIpRange(ctx context.Context, st composed.State) (error, context.Context
WithValues("ipRange", ipRangeName).
Error(err, "Referred IpRange does not exist")
meta.SetStatusCondition(redisInstance.Conditions(), metav1.Condition{
Type: cloudresourcesv1beta1.ConditionTypeError,
Type: cloudcontrolv1beta1.ConditionTypeError,
Status: "True",
Reason: cloudresourcesv1beta1.ReasonInvalidIpRangeReference,
Reason: cloudcontrolv1beta1.ReasonInvalidIpRangeReference,
Message: fmt.Sprintf("Referred IpRange %s/%s does not exist", state.Obj().GetNamespace(), ipRangeName),
})
redisInstance.SetStatusStateToError()
Expand Down
4 changes: 2 additions & 2 deletions pkg/kcp/redisinstance/reconciler.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"github.com/kyma-project/cloud-manager/pkg/kcp/provider/gcp/redisinstance"
"sigs.k8s.io/controller-runtime/pkg/reconcile"

cloudresourcesv1beta1 "github.com/kyma-project/cloud-manager/api/cloud-control/v1beta1"
cloudcontrolv1beta1 "github.com/kyma-project/cloud-manager/api/cloud-control/v1beta1"
"github.com/kyma-project/cloud-manager/pkg/common/actions/focal"
"github.com/kyma-project/cloud-manager/pkg/composed"
"k8s.io/apimachinery/pkg/types"
Expand Down Expand Up @@ -65,6 +65,6 @@ func (r *redisInstanceReconciler) newAction() composed.Action {

func (r *redisInstanceReconciler) newFocalState(name types.NamespacedName) focal.State {
return r.focalStateFactory.NewState(
r.composedStateFactory.NewState(name, &cloudresourcesv1beta1.RedisInstance{}),
r.composedStateFactory.NewState(name, &cloudcontrolv1beta1.RedisInstance{}),
)
}

0 comments on commit 5cdaf12

Please sign in to comment.