Skip to content

Commit

Permalink
Fix subscription ratelimit update
Browse files Browse the repository at this point in the history
  • Loading branch information
Tharsanan1 committed Oct 10, 2024
1 parent 1e2b423 commit bce5d25
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apim-apk-agent/internal/k8sClient/k8s_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,7 @@ func UpdateRateLimitPolicyCR(policy eventhubTypes.RateLimitPolicy, k8sClient cli
func DeploySubscriptionRateLimitPolicyCR(policy eventhubTypes.SubscriptionPolicy, k8sClient client.Client) {
conf, _ := config.ReadConfigs()
crRateLimitPolicy := dpv1alpha3.RateLimitPolicy{}
if err := k8sClient.Get(context.Background(), client.ObjectKey{Namespace: conf.DataPlane.Namespace, Name: policy.Name}, &crRateLimitPolicy); err != nil {
if err := k8sClient.Get(context.Background(), client.ObjectKey{Namespace: conf.DataPlane.Namespace, Name: getSha1Value(fmt.Sprintf("%s-%s",policy.Name, policy.TenantDomain))}, &crRateLimitPolicy); err != nil {
crRateLimitPolicy = dpv1alpha3.RateLimitPolicy{
ObjectMeta: metav1.ObjectMeta{
Name: getSha1Value(fmt.Sprintf("%s-%s",policy.Name, policy.TenantDomain)),
Expand Down

0 comments on commit bce5d25

Please sign in to comment.