From 1901faf6a91ea15007f35d0966a55ab8eb45511e Mon Sep 17 00:00:00 2001 From: "antoine.choimet" Date: Tue, 12 Nov 2024 15:32:25 +0100 Subject: [PATCH] fix: conversion error --- extkafka/alter_limit_connection_create_rate.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extkafka/alter_limit_connection_create_rate.go b/extkafka/alter_limit_connection_create_rate.go index 647ba4e..670bdf3 100644 --- a/extkafka/alter_limit_connection_create_rate.go +++ b/extkafka/alter_limit_connection_create_rate.go @@ -71,7 +71,7 @@ func (k *AlterLimitConnectionCreateRateAttack) Describe() action_kit_api.ActionD func (k *AlterLimitConnectionCreateRateAttack) Prepare(_ context.Context, state *AlterLimitConnectionCreateRateState, request action_kit_api.PrepareActionRequestBody) (*action_kit_api.PrepareResult, error) { state.BrokerID = extutil.ToInt32(request.Target.Attributes["kafka.broker.node-id"][0]) - state.BrokerConfigValue = fmt.Sprintf("%f", request.Config["connection_rate"]) + state.BrokerConfigValue = fmt.Sprintf("%d", int(extutil.ToInt64(request.Config["connection_rate"]))) return nil, nil }