lib/mb/config.rb in motherbrain-0.14.5 vs lib/mb/config.rb in motherbrain-1.0.0
- old
+ new
@@ -119,10 +119,14 @@
attribute 'ssl.verify',
default: true,
type: Boolean
+ attribute 'ridley.connector_pool_size',
+ default: 25,
+ type: Integer
+
attribute 'log.level',
default: 'INFO',
type: String,
coerce: lambda { |m|
m = m.is_a?(String) ? m.upcase : m
@@ -252,9 +256,15 @@
ridley_opts[:ssh] = self.ssh
ridley_opts[:winrm] = self.winrm
ridley_opts[:ssl] = {
verify: self.ssl.verify
}
+
+ ridley_opts[:connector_pool_size] = if ENV.has_key?('MB_CONNECTOR_POOL')
+ ENV['MB_CONNECTOR_POOL'].to_i
+ else
+ ridley.connector_pool_size
+ end
ridley_opts[:ssh][:verbose] = ridley_opts[:ssh][:verbose].to_sym if ridley_opts[:ssh][:verbose]
end
end
def to_rest_gateway