Revision 5780e8a0
Added by Evgeni Golov about 1 year ago
spec/classes/pulpcore_spec.rb | ||
---|---|---|
is_expected.to contain_pulpcore__socket_service('pulpcore-api')
|
||
is_expected.to contain_systemd__unit_file('pulpcore-api.socket')
|
||
is_expected.to contain_systemd__unit_file('pulpcore-api.service').with_content(%r{--workers 2})
|
||
.with_content(%r{--max-requests 50})
|
||
.with_content(%r{--max-requests-jitter 30})
|
||
is_expected.to contain_file('/etc/systemd/system/pulpcore-api.socket').that_comes_before('Service[pulpcore-api.service]')
|
||
is_expected.to contain_pulpcore__socket_service('pulpcore-content')
|
||
is_expected.to contain_systemd__unit_file('pulpcore-content.socket')
|
||
... | ... | |
end
|
||
end
|
||
|
||
context 'with changed max-requests' do
|
||
let :params do
|
||
{
|
||
api_service_worker_max_requests: 100,
|
||
api_service_worker_max_requests_jitter: 10
|
||
}
|
||
end
|
||
|
||
it do
|
||
is_expected.to compile.with_all_deps
|
||
is_expected.to contain_systemd__unit_file('pulpcore-api.service')
|
||
.with_content(%r{--max-requests 100})
|
||
.with_content(%r{--max-requests-jitter 10})
|
||
end
|
||
end
|
||
|
||
context 'with allowed import paths' do
|
||
let :params do
|
||
{
|
Also available in: Unified diff
Fixes #36438 - configure API request limit to avoid memory leaks