Make ES Heap Size configurable.
wiki.o.o is much smaller than our typical elasticsearch nodes. For it to use elasticsearch it needs to allocate a much smaller heap. Make the heap size configurable (keep the 16g default) and set the heap size to 1g for wiki.o.o. Change-Id: I0c5fb4865eb07c0fa5bbe4cf698a9f0e9ea9f2fc
This commit is contained in:
parent
5a463e3c8e
commit
053f98b4ee
@ -16,7 +16,8 @@
|
|||||||
#
|
#
|
||||||
class elasticsearch (
|
class elasticsearch (
|
||||||
$discover_nodes = ['localhost'],
|
$discover_nodes = ['localhost'],
|
||||||
$version = '0.20.5'
|
$version = '0.20.5',
|
||||||
|
$heap_size = '16g'
|
||||||
) {
|
) {
|
||||||
# install java runtime
|
# install java runtime
|
||||||
package { 'java7-runtime-headless':
|
package { 'java7-runtime-headless':
|
||||||
@ -96,7 +97,7 @@ class elasticsearch (
|
|||||||
|
|
||||||
file { '/etc/default/elasticsearch':
|
file { '/etc/default/elasticsearch':
|
||||||
ensure => present,
|
ensure => present,
|
||||||
source => 'puppet:///modules/elasticsearch/elasticsearch.default',
|
content => template('elasticsearch/elasticsearch.default.erb'),
|
||||||
replace => true,
|
replace => true,
|
||||||
owner => 'root',
|
owner => 'root',
|
||||||
group => 'root',
|
group => 'root',
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#ES_GROUP=elasticsearch
|
#ES_GROUP=elasticsearch
|
||||||
|
|
||||||
# Heap Size (defaults to 256m min, 1g max)
|
# Heap Size (defaults to 256m min, 1g max)
|
||||||
ES_HEAP_SIZE=16g
|
ES_HEAP_SIZE=<%= heap_size %>
|
||||||
|
|
||||||
# Heap new generation
|
# Heap new generation
|
||||||
#ES_HEAP_NEWSIZE=
|
#ES_HEAP_NEWSIZE=
|
@ -60,6 +60,7 @@ class openstack_project::wiki (
|
|||||||
class { '::elasticsearch':
|
class { '::elasticsearch':
|
||||||
discover_nodes => ['localhost'],
|
discover_nodes => ['localhost'],
|
||||||
version => '0.90.5',
|
version => '0.90.5',
|
||||||
|
heap_size => '1g',
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user