Sha256: 052744d0aa41e6b2df1d0a34efa61472984ad47dc7c4040f882ea4024f2a9186
Contents?: true
Size: 517 Bytes
Versions: 59
Compression:
Stored size: 517 Bytes
Contents
# encoding: utf-8 require "logstash/config/defaults" module LogStash module Config module CpuCoreStrategy extend self def maximum LogStash::Config::Defaults.cpu_cores end def fifty_percent [1, (maximum * 0.5)].max.floor end def seventy_five_percent [1, (maximum * 0.75)].max.floor end def twenty_five_percent [1, (maximum * 0.25)].max.floor end def max_minus_one [1, (maximum - 1)].max.floor end def max_minus_two [1, (maximum - 2)].max.floor end end end end
Version data entries
59 entries across 59 versions & 1 rubygems