Merge pull request #13112 from HJianBo/change-the-default-batch-size-s3-uploader

Fix(s3): change the batch_size to 1 for direct mode
This commit is contained in:
zmstone 2024-05-24 10:56:53 +02:00 committed by GitHub
commit 6ec8ae5a5f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 5 additions and 5 deletions

View File

@ -21,7 +21,7 @@ endif
# Dashboard version
# from https://github.com/emqx/emqx-dashboard5
export EMQX_DASHBOARD_VERSION ?= v1.9.0-beta.1
export EMQX_EE_DASHBOARD_VERSION ?= e1.7.0-beta.11
export EMQX_EE_DASHBOARD_VERSION ?= e1.7.0-beta.12
-include default-profile.mk
PROFILE ?= emqx

View File

@ -238,12 +238,12 @@ convert_actions(undefined, _) ->
convert_action(Conf = #{<<"parameters">> := Params, <<"resource_opts">> := ResourceOpts}, _) ->
case Params of
#{<<"mode">> := <<"direct">>} ->
#{<<"mode">> := <<"aggregated">>} ->
Conf;
#{} ->
%% NOTE: Disable batching for direct uploads.
NResourceOpts = ResourceOpts#{<<"batch_size">> => 1, <<"batch_time">> => 0},
Conf#{<<"resource_opts">> := NResourceOpts};
#{} ->
Conf
Conf#{<<"resource_opts">> := NResourceOpts}
end.
%% Interpreting options