mirror of
https://github.com/valitydev/limiter.git
synced 2024-11-06 00:55:22 +00:00
bcff0b78f6
* CP-12: Adds support for 'currency_conversin' config option * Fixes eunit tests * Updates testcases in suites * Fixes struct type in marshaling and temporarily disables codecov report upload * Bumps damsel and limiter-proto * Removes global 'currency_conversion' flag
127 lines
3.6 KiB
Plaintext
127 lines
3.6 KiB
Plaintext
[
|
|
{limiter, [
|
|
{ip, "::"},
|
|
{port, 8022},
|
|
{services, #{
|
|
limiter => #{
|
|
path => <<"/v1/limiter">>
|
|
},
|
|
configurator => #{
|
|
path => <<"/v1/configurator">>
|
|
}
|
|
}},
|
|
{service_clients, #{
|
|
accounter => #{
|
|
url => <<"http://shumway:8022/accounter">>
|
|
},
|
|
automaton => #{
|
|
url => <<"http://machinegun:8022/v1/automaton">>
|
|
},
|
|
xrates => #{
|
|
url => <<"http://xrates:8022/xrates">>
|
|
}
|
|
}},
|
|
|
|
{exchange_factors, #{
|
|
<<"DEFAULT">> => {1, 1},
|
|
<<"USD">> => {105, 100},
|
|
<<"EUR">> => {12, 10}
|
|
}},
|
|
|
|
{protocol_opts, #{
|
|
% How much to wait for another request before closing a keepalive connection? (ms)
|
|
request_timeout => 5000,
|
|
% Should be greater than any other timeouts
|
|
idle_timeout => infinity
|
|
}},
|
|
{transport_opts, #{
|
|
% Maximum number of simultaneous connections. (default = 1024)
|
|
max_connections => 8000,
|
|
% Size of the acceptor pool. (default = 10)
|
|
num_acceptors => 100
|
|
}},
|
|
% How much to wait for outstanding requests completion when asked to shut down? (ms)
|
|
{shutdown_timeout, 1000},
|
|
|
|
{woody_event_handlers, [
|
|
{scoper_woody_event_handler, #{
|
|
event_handler_opts => #{
|
|
formatter_opts => #{
|
|
max_length => 1000,
|
|
max_printable_string_length => 80
|
|
}
|
|
}
|
|
}}
|
|
]},
|
|
|
|
{scoper_event_handler_options, #{
|
|
event_handler_opts => #{
|
|
formatter_opts => #{
|
|
max_length => 1000,
|
|
max_printable_string_length => 80
|
|
}
|
|
}
|
|
}},
|
|
|
|
{health_check, #{
|
|
% disk => {erl_health, disk , ["/", 99]},
|
|
% memory => {erl_health, cg_memory, [99]},
|
|
% service => {erl_health, service , [<<"limiter">>]}
|
|
}}
|
|
]},
|
|
|
|
{dmt_client, [
|
|
% milliseconds
|
|
{cache_update_interval, 5000},
|
|
{max_cache_size, #{
|
|
elements => 20,
|
|
% 50Mb
|
|
memory => 52428800
|
|
}},
|
|
{woody_event_handlers, [
|
|
{scoper_woody_event_handler, #{
|
|
event_handler_opts => #{
|
|
formatter_opts => #{
|
|
max_length => 1000
|
|
}
|
|
}
|
|
}}
|
|
]},
|
|
{service_urls, #{
|
|
'Repository' => <<"http://dominant:8022/v1/domain/repository">>,
|
|
'RepositoryClient' => <<"http://dominant:8022/v1/domain/repository_client">>
|
|
}}
|
|
]},
|
|
|
|
{kernel, [
|
|
{logger_sasl_compatible, false},
|
|
{logger_level, debug},
|
|
{logger, [
|
|
{handler, default, logger_std_h, #{
|
|
level => error,
|
|
config => #{type => standard_error},
|
|
formatter => {logger_formatter, #{depth => 30}}
|
|
}},
|
|
{handler, console, logger_std_h, #{
|
|
config => #{
|
|
type => {file, "/var/log/limiter/log.json"}
|
|
},
|
|
formatter => {logger_logstash_formatter, #{}}
|
|
}}
|
|
]}
|
|
]},
|
|
|
|
{os_mon, [
|
|
% for better compatibility with busybox coreutils
|
|
{disksup_posix_only, true}
|
|
]},
|
|
|
|
{scoper, [
|
|
{storage, scoper_storage_logger}
|
|
]},
|
|
|
|
{prometheus, [
|
|
{collectors, [default]}
|
|
]}
|
|
].
|