From bb6c74b246b3db290d0bffacb1e39dc61ffec08f Mon Sep 17 00:00:00 2001 From: Swann Croiset Date: Thu, 2 Jul 2015 12:35:19 +0200 Subject: [PATCH] Add Heka params to set maximum message injection This add these Heka configuration options in global.toml If not provided, use the Heka default values which are currently: * max_process_inject = 1 * max_timer_inject = 10 Change-Id: If1995fa505aec6ff3000af33c548730dd06d1046 --- deployment_scripts/puppet/modules/heka/manifests/init.pp | 8 ++++++++ .../puppet/modules/heka/manifests/params.pp | 2 ++ .../puppet/modules/heka/templates/global.toml.erb | 6 ++++++ 3 files changed, 16 insertions(+) diff --git a/deployment_scripts/puppet/modules/heka/manifests/init.pp b/deployment_scripts/puppet/modules/heka/manifests/init.pp index 1331ad4ce..060d98c7c 100644 --- a/deployment_scripts/puppet/modules/heka/manifests/init.pp +++ b/deployment_scripts/puppet/modules/heka/manifests/init.pp @@ -41,6 +41,12 @@ # [*max_message_size*] # The maxium Heka message size in bytes (default: undef to use default Heka value). # +# [*max_process_inject*] +# The maximum number of messages that a sandbox filter’s ProcessMessage function can inject in a single call (default: undef to use default Heka value). +# +# [*max_timer_inject*] +# The maximum number of messages that a sandbox filter’s TimerEvent function can inject in a single call (default: undef to use default Heka value). +# # [*dashboard_address*] # The listening adddress for the Heka dashboard (default: undef). # @@ -74,6 +80,8 @@ class heka ( $hostname = $heka::params::hostname, $maxprocs = $heka::params::maxprocs, $max_message_size = $heka::params::max_message_size, + $max_process_inject = $heka::params::max_process_inject, + $max_timer_inject = $heka::params::max_timer_inject, $dashboard_address = $heka::params::dashboard_address, $dashboard_port = $heka::params::dashboard_port, $pre_script = undef, diff --git a/deployment_scripts/puppet/modules/heka/manifests/params.pp b/deployment_scripts/puppet/modules/heka/manifests/params.pp index 4ef990084..5f1234dbf 100644 --- a/deployment_scripts/puppet/modules/heka/manifests/params.pp +++ b/deployment_scripts/puppet/modules/heka/manifests/params.pp @@ -22,6 +22,8 @@ class heka::params { $hostname = undef $maxprocs = $::processorcount $max_message_size = undef + $max_process_inject = undef + $max_timer_inject = undef $dashboard_address = undef $dashboard_port = '4352' $internal_statistics = false diff --git a/deployment_scripts/puppet/modules/heka/templates/global.toml.erb b/deployment_scripts/puppet/modules/heka/templates/global.toml.erb index 72dc25f1f..2ad5cf40e 100644 --- a/deployment_scripts/puppet/modules/heka/templates/global.toml.erb +++ b/deployment_scripts/puppet/modules/heka/templates/global.toml.erb @@ -7,3 +7,9 @@ hostname="<%= @hostname %>" <% if @max_message_size -%> max_message_size = <%= @max_message_size %> <% end -%> +<% if @max_process_inject -%> +max_process_inject = <%= @max_process_inject %> +<% end -%> +<% if @max_timer_inject -%> +max_timer_inject = <%= @max_timer_inject %> +<% end -%>