
This patch fixes the order of the middlewares defined in the Swift proxy server pipeline. Sources for the order: https://github.com/openstack/swift/blob/master/etc/proxy-server.conf-sample#L91-L99 http://docs.openstack.org/developer/swift/middleware.html# https://github.com/openstack/swift3/blob/master/etc/proxy-server.conf-sample#L9 https://github.com/openstack/ceilometermiddleware/blob/master/ceilometermiddleware/swift.py#L21-L22 These are all values in order: 10 catch_errors 20 gatekeeper 30 healthcheck 40 (reserved for proxy_logging, see below) 50 cache 60 container_sync 70 swift3 80 s3token 90 ratelimit 100 crossdomain 110 bulk 120 tempurl 130 formpost 140 copy 150 tempauth 160 swauth 170 authtoken 180 keystone 190 staticweb 200 copy 210 account_quotas 220 container_quotas 230 slo 240 dlo 250 versioned_writes 260 ceilometer 270 proxy-logging 280 proxy-server The copy and versioned_writes middlewares have been added too. The proxy_logging should be added a second time at position 40, but the actual value is 270 to have the final proxy-logging just before the proxy-server. Also renamed the suffix 'swauth' in the 'tempauth' manifest to be 'tempauth'; 'swauth' is used in a different manifest. Closes-Bug: 1618514 Change-Id: I99433720e32dc3557b809c8d42ce3d5981c199c3
61 lines
1.3 KiB
Puppet
61 lines
1.3 KiB
Puppet
#
|
|
# Configure swift slo.
|
|
#
|
|
# == Examples
|
|
#
|
|
# include swift::proxy::slo
|
|
#
|
|
# == Parameters
|
|
#
|
|
# [*max_manifest_segments*]
|
|
# Max manifest segments.
|
|
# Default to 1000.
|
|
#
|
|
# [*max_manifest_size*]
|
|
# Max manifest size.
|
|
# Default to 2097152.
|
|
#
|
|
# [*min_segment_size*]
|
|
# minimal segment size
|
|
# Default to 1048576.
|
|
#
|
|
# [*rate_limit_after_segment*]
|
|
# Start rate-limiting SLO segment serving after the Nth segment of a segmented object.
|
|
# Default to 10.
|
|
#
|
|
# [*rate_limit_segments_per_sec*]
|
|
# Once segment rate-limiting kicks in for an object, limit segments served to N per second.
|
|
# 0 means no rate-limiting.
|
|
# Default to 0.
|
|
#
|
|
# [*max_get_time*]
|
|
# Time limit on GET requests (seconds).
|
|
# Default to 86400.
|
|
#
|
|
# == Authors
|
|
#
|
|
# Xingchao Yu yuxcer@gmail.com
|
|
#
|
|
# == Copyright
|
|
#
|
|
# Copyright 2014 UnitedStack licensing@unitedstack.com
|
|
#
|
|
class swift::proxy::slo (
|
|
$max_manifest_segments = '1000',
|
|
$max_manifest_size = '2097152',
|
|
$min_segment_size = '1048576',
|
|
$rate_limit_after_segment = '10',
|
|
$rate_limit_segments_per_sec = '0',
|
|
$max_get_time = '86400'
|
|
) {
|
|
|
|
include ::swift::deps
|
|
|
|
concat::fragment { 'swift_slo':
|
|
target => '/etc/swift/proxy-server.conf',
|
|
content => template('swift/proxy/slo.conf.erb'),
|
|
order => '230',
|
|
}
|
|
|
|
}
|