Peter Portante 3ad78098b5 object-storage: Refactor code to reduce Swift diffs carried
The upstream Swift code base contains the following commit which adds the
ability to modify constraint values using the swift.conf file:

 a2ac5efaa6

These changes rely on the above commit being back-ported to Swift 1.4.8 (see
fc2421b040).

As a result, a good number of differences we carry can be removed, since the
provided swift.conf file now contains the values we need.

Along with these changes, we add middleware to get constraints loaded properly
(via monkey patching) until subclassing is implemented in a future commit. We
further simplify the diffs to a minimal set by storing the timestamp in file
system metadata and moving new files to the plugins/middleware directory.

Note that the original "gluster" middleware was in the swift.diff file, and
has been renamed to "glusterfs" and moved to the new plugins/middleware
directory. The "gluster" middleware is now a temporary way to get the
constraints properly loaded (both of these middleware pieces should disappear
in future commits when we refactor further to subclass the Swift objects
instead of patching them).

Change-Id: I9dc00d6b6cdd64e277896d75c2fb06431c3e69cb
BUG: 862052
Signed-off-by: Peter Portante <peter.portante@redhat.com>
Reviewed-on: http://review.gluster.org/4093
Tested-by: Peter Portante <pportant@redhat.com>
Reviewed-by: Anand Avati <avati@redhat.com>
2013-04-29 16:35:55 -04:00

93 lines
2.8 KiB
Plaintext

[DEFAULT]
Enable_plugin = yes
[swift-hash]
# random unique string that can never change (DO NOT LOSE)
swift_hash_path_suffix = gluster
# The swift-constraints section sets the basic constraints on data
# saved in the swift cluster.
[swift-constraints]
# max_file_size is the largest "normal" object that can be saved in
# the cluster. This is also the limit on the size of each segment of
# a "large" object when using the large object manifest support.
# This value is set in bytes. Setting it to lower than 1MiB will cause
# some tests to fail. It is STRONGLY recommended to leave this value at
# the default (5 * 2**30 + 2).
# FIXME: Really? Gluster can handle a 2^64 sized file? And can the fronting
# web service handle such a size? I think with UFO, we need to keep with the
# default size from Swift and encourage users to research what size their web
# services infrastructure can handle.
max_file_size = 18446744073709551616
# max_meta_name_length is the max number of bytes in the utf8 encoding
# of the name portion of a metadata header.
#max_meta_name_length = 128
# max_meta_value_length is the max number of bytes in the utf8 encoding
# of a metadata value
#max_meta_value_length = 256
# max_meta_count is the max number of metadata keys that can be stored
# on a single account, container, or object
#max_meta_count = 90
# max_meta_overall_size is the max number of bytes in the utf8 encoding
# of the metadata (keys + values)
#max_meta_overall_size = 4096
# max_object_name_length is the max number of bytes in the utf8 encoding of an
# object name: Gluster FS can handle much longer file names, but the length
# between the slashes of the URL is handled below. Remember that most web
# clients can't handle anything greater than 2048, and those that do are
# rather clumsy.
max_object_name_length = 2048
# max_object_name_component_length (GlusterFS) is the max number of bytes in
# the utf8 encoding of an object name component (the part between the
# slashes); this is a limit imposed by the underlying file system (for XFS it
# is 255 bytes).
max_object_name_component_length = 255
# container_listing_limit is the default (and max) number of items
# returned for a container listing request
#container_listing_limit = 10000
# account_listing_limit is the default (and max) number of items returned
# for an account listing request
#account_listing_limit = 10000
# max_account_name_length is the max number of bytes in the utf8 encoding of
# an account name: Gluster FS Filename limit (XFS limit?), must be the same
# size as max_object_name_component_length above.
max_account_name_length = 255
# max_container_name_length is the max number of bytes in the utf8 encoding
# of a container name: Gluster FS Filename limit (XFS limit?), must be the same
# size as max_object_name_component_length above.
max_container_name_length = 255