842 Commits

Author SHA1 Message Date
Prashanth Pai
46d61a4dcd Refactor server side copy as middleware
Rewrite server side copy and 'object post as copy' feature as middleware to
simplify the PUT method in the object controller code. COPY is no longer
a verb implemented as public method in Proxy application.

The server side copy middleware is inserted to the left of dlo, slo and
versioned_writes middlewares in the proxy server pipeline. As a result,
dlo and slo copy_hooks are no longer required. SLO manifests are now
validated when copied so when copying a manifest to another account the
referenced segments must be readable in that account for the manifest
copy to succeed (previously this validation was not made, meaning the
manifest was copied but could be unusable if the segments were not
readable).

With this change, there should be no change in functionality or existing
behavior. This is asserted with (almost) no changes required to existing
functional tests.

Some notes (for operators):
* Middleware required to be auto-inserted before slo and dlo and
  versioned_writes
* Turning off server side copy is not configurable.
* object_post_as_copy is no longer a configurable option of proxy server
  but of this middleware. However, for smooth upgrade, config option set
  in proxy server app is also read.

DocImpact: Introducing server side copy as middleware

Co-Authored-By: Alistair Coles <alistair.coles@hpe.com>
Co-Authored-By: Thiago da Silva <thiago@redhat.com>

Change-Id: Ic96a92e938589a2f6add35a40741fd062f1c29eb
Signed-off-by: Prashanth Pai <ppai@redhat.com>
Signed-off-by: Thiago da Silva <thiago@redhat.com>
2016-05-11 14:55:51 -04:00
oshritf
c96d5c671d Per container stat. report
In addition to the container sync stat. report, keeping per container
statistics allows administrator with more control over bytes
transfered over a specific time per user account: The per container stats
are crucial for billing purposes and provides the operator a 'progress
bar' equivalent on the container's replication status.

Change-Id: Ia8abcdaf53e466e8d60a957c76e32c2b2c5dc3fa
2016-04-14 21:37:59 +03:00
Ondřej Nový
33f06dc48f Fixed Sphinx errors
doc/source/deployment_guide.rst:1372: ERROR: Malformed table.
swift/obj/diskfile.py:docstring of swift.obj.diskfile.BaseDiskFileManager.yield_hashes:13: ERROR: Unexpected indentation.
doc/source/ops_runbook/diagnose.rst:188: WARNING: Inline emphasis start-string without end-string.

Change-Id: Id20eb62eb5baebb3814e7af5676badb94f17dee5
2016-04-09 18:47:58 +02:00
Nguyen Hung Phuong
edc413b85e Fix typos in Swift files
Change-Id: I39dbf55c094c42347b57ef67520abff9e6fc24bc
2016-04-07 13:33:20 +07:00
Thiago da Silva
a460e5affe added javaswift to associated projects
Change-Id: I139ac3acb1c7d2498e87df554b81824ada2dbd00
Signed-off-by: Thiago da Silva <thiago@redhat.com>
2016-04-04 16:27:14 -04:00
KATO Tomoyuki
ee6af69af4 [docs] Update Administrator Guide URL
Change-Id: I7f6f4ffb7033d2a321362c91e05f1576847939b0
2016-04-01 23:38:49 +09:00
Nguyen Hung Phuong
59bbe27fb0 Fix typos in Swift files
Change-Id: I34e0c9a888127704ac1910e73ddd14e27ebade13
2016-03-30 04:15:23 +00:00
Anh Tran
2f7d0f4a2a Removing some redundant words
This patch removes some redundant words.

Change-Id: Ia79717664b06ed9a41c3c5dcf1a25e9e49e21cf2
2016-03-25 17:20:24 +07:00
Jenkins
4be3701805 Merge "Auditor will clean up stale rsync tempfiles" 2016-03-23 22:21:51 +00:00
Clay Gerrard
1d03803a85 Auditor will clean up stale rsync tempfiles
DiskFile already fills in the _ondisk_info attribute when it tries to open
a diskfile - even if the DiskFile's fileset is not valid or deleted.
During this process the rsync tempfiles would be discovered and logged,
but no-one would attempt to clean them up - even if they were really old.

Instead of logging and ignoring unexpected files when validate a DiskFile
fileset we'll add unexpected files to the unexpected key in the
_ondisk_info attribute.

With a little bit of re-organization in the auditor's object_audit method
to get things into a single return path we can add an unconditional check
for unexpected files and remove those that are "old enough".

Since the replicator will kill any rsync processes that are running longer
than the configured rsync_timeout we know that any rsync tempfiles older
than this can be deleted.

Split unlink_older_than in common.utils into two functions to allow an
explicit list of previously discovered paths to be passed in to avoid an
extra listdir.  Since the getmtime handling already ignores OSError
there's less concern of race condition where a previous discovered
unexpected file is reaped by rsync while we're attempting to clean it up.

Update some doc on the new config option.

Closes-Bug: #1554005

Change-Id: Id67681cb77f605e3491b8afcb9c69d769e154283
2016-03-23 19:34:34 +00:00
Jenkins
32847d2f48 Merge "Docs: Container sync does not require POST-as-COPY" 2016-03-23 17:08:26 +00:00
Alistair Coles
736de613f1 Docs: Container sync does not require POST-as-COPY
Updates docs to remove warnings that container sync only
works with object_post_as_copy=True. Since commit e91de49
container sync will also sync POST updates when using
object_post_as_copy=False.

Change-Id: I5cc3cc6e8f9ba2fef6f896f2b11d2a4e06825f7f
2016-03-22 11:36:32 +00:00
Jenkins
4eb57e971d Merge "Add concurrent reads option to proxy" 2016-03-18 23:11:04 +00:00
Jenkins
7cc2c783a4 Merge "Keystone middleware deprecated option is_admin removed" 2016-03-18 10:51:46 +00:00
Jenkins
1637fa2f8f Merge "Make keystone middleware options consistent in docs" 2016-03-18 10:43:23 +00:00
Jenkins
ead9b56743 Merge "Update ring overview for reuse of device ids" 2016-03-18 00:48:20 +00:00
Paul Dardeau
a85149c40e Update ring overview for reuse of device ids
Change-Id: Ied15706d4cc931b5314001a02457f83e175c5d24
2016-03-17 22:24:12 +00:00
Alistair Coles
6efee0ebb1 Make keystone middleware options consistent in docs
Bring overview_auth.rst and proxy server man page
up to date with changes made in [1]

[1] Change-Id: I373734933189c87c4094203b0752dd3762689034

Change-Id: Ia16f0c391e7c357ccb9c13945839dc5647e49a13
2016-03-16 11:43:20 +00:00
Kota Tsuyuzaki
ecbcc94989 Fix ssync related object-server docs
Swift now uses SSYNC verb instead of old REPLICATION verb for ssync
protocol. This patch replaces all docs written as REPLICATION into
SSYNC and fix a few words for explanation.

Change-Id: I1253210d4f49749e7d425d6252dd262b650d9548
2016-03-16 08:58:31 +00:00
Matthew Oliver
f595a7e704 Add concurrent reads option to proxy
This change adds 2 new parameters to enable and control concurrent GETs
in swift, these are 'concurrent_gets' and 'concurrency_timeout'.

'concurrent_gets' allows you to turn on or off concurrent GETs, when
on it will set the GET/HEAD concurrency to replica count. And in the
case of EC HEADs it will set it to ndata.
The proxy will then serve only the first valid source to respond.
This applies to all account, container and object GETs except
for EC. For EC only HEAD requests are effected.

It achieves this by changing the request sending mechanism to using
GreenAsyncPile and green threads with a time out between each
request.

'concurrency_timeout' is related to concurrent_gets. And is the
amount of time to wait before firing the next thread. A value of 0
will fire at the same time (fully concurrent), setting another value
will stagger the firing allowing you the ability to give a node a
shorter chance to respond before firing the next. This value is a float
and should be somewhere between 0 and node_timeout. The default is
conn_timeout. Meaning by default it will stagger the firing.

DocImpact
Implements: blueprint concurrent-reads
Change-Id: I789d39472ec48b22415ff9d9821b1eefab7da867
2016-03-16 06:00:34 +00:00
Jenkins
cdee5b6d01 Merge "Remove reference to py26 in tox testing instructions" 2016-03-15 00:12:08 +00:00
Alistair Coles
3ac7cab32b Remove reference to py26 in tox testing instructions
Also change some rst formatting and clarify that tox
is used to run more than just *unit* tests.

Change-Id: I263af7b4f7a554da3a391cf5104af573c89e3825
2016-03-11 11:50:49 +00:00
Jenkins
557192c47e Merge "Cleanup of Swift Ops Runbook" 2016-03-11 00:57:48 +00:00
Donagh McCabe
e38b53393f Cleanup of Swift Ops Runbook
This patch cleans up some rough edges that were left (due to
time constraints) in the original commit.

Change-Id: Id4480be8dc1b5c920c19988cb89ca8b60ace91b4
Co-Authored-By: Gerry Drudy gerry.drudy@hpe.com
2016-03-10 17:39:54 +00:00
Jenkins
9f396e2d2e Merge "Fixed pep8 and flake8 errors in doc/source/conf.py and updated flake8 commands in tox.ini to test it." 2016-03-08 16:28:27 +00:00
Olga Saprycheva
2cff2dec3d Fixed pep8 and flake8 errors in doc/source/conf.py and updated flake8 commands in tox.ini to test it.
Change-Id: I2add370e4cfb55d1388e3a8b41f688a7f3f2c621
2016-03-07 10:39:37 -06:00
Jenkins
1a69b14e7a Merge "Remove Erasure Coding beta status from docs" 2016-03-05 15:42:17 +00:00
Jenkins
9891039b8d Merge "Remove unused pngmath Sphinx extension" 2016-03-04 19:32:15 +00:00
Christian Schwede
043fbca6d0 Remove Erasure Coding beta status from docs
This removes notes stating support for Erasure coding as beta. Questions
regarding the stability of EC are coming up regularly, and are often referring
to the docs that state EC as still in beta.

Besides this, a note marking statsd support as beta has been removed as well.

Change-Id: If4fb6a5c4cb741d42953db3cee8cb17a1d774e15
2016-03-04 14:27:23 +00:00
asettle
3c61ab4678 Operational procedures guide
This is the operational procedures guide that HPE used
to operate and monitor their public Swift systems.
It has been made publicly available.

Change-Id: Iefb484893056d28beb69265d99ba30c3c84add2b
2016-03-03 11:49:26 +00:00
Jenkins
368423df3d Merge "Use uppercase 'S' in word "OpenStack"" 2016-03-01 16:21:41 +00:00
Andreas Jaeger
087fa4fa01 Remove unused pngmath Sphinx extension
There's no RST file that uses ".. math" and thus
the pngmath Sphinx extension is not used and can
get removed.

Change-Id: I3ea4b529025c8ac3c4092f3720124647861e6668
2016-02-29 20:00:38 +01:00
John Dickinson
9e53bb47ef updated some weird whitespace character to a normal one
Change-Id: I187fb8fc8d10f950bbebc586999eced0bc117432
2016-02-24 09:48:57 -08:00
Kazuhiro MIYAHARA
c3201f256c Remove execute permissions from doc files and swift.conf-sample
Some doc files and swift.conf-sample were added execute permissions in past changes.
This patch remove execute permissions from them.

Change-Id: Id8844989a8321578e9207566ebd6660f5b9523f0
2016-02-18 08:52:03 +00:00
Jenkins
8bec700e7b Merge "Add note on using printable chars for swift_hash_path_suffix/prefix" 2016-02-18 00:23:28 +00:00
Jenkins
6d6629f7b1 Merge "Added links to API reference and usage guides" 2016-02-17 22:03:58 +00:00
Christian Schwede
e46d6b1725 Add note on using printable chars for swift_hash_path_suffix/prefix
Using unprintable characters for swift_hash_path_prefix/suffix might lead to
hard problems when parsing of these values changes, for example due to newer
Python versions or changes in the parsers itself. Let's avoid this and add a
note that deployers should use printable strings for these values.

Change-Id: I976982b753b6af831ab91d7190f50f8f15bf73bf
2016-02-17 20:47:53 +01:00
Donagh McCabe
b8fa480808 Added links to API reference and usage guides
Added a link to the API reference (where headers and query
strings are documented; click the "detail" button to see).
Also added a reference to Swift section of the OpenStack end
user guide. This contains some additional details about the API.

No attempt was made to reconcile duplicate information. Instead
this patch links documents that might otherwise be overlooked.
However, I fixed text, originally in a table, that had become
garbled in a prior patch.

Change-Id: I0910cbeb0c8bffc00e510f35585603e7b7a67790
2016-02-17 18:39:22 +00:00
Christian Schwede
42f4b3fc1e Add SwiftHLM to associated projects
Change-Id: I5ea3de34e61f22abec803b35fec8adde18a793e9
2016-02-16 13:53:52 +00:00
Jenkins
02fb983dc6 Merge "Removed unused parameter in server.py" 2016-02-12 00:39:57 +00:00
Ondřej Nový
335d58611d Keystone middleware deprecated option is_admin removed
It has been deprecated from Swift 1.8.0 (Grizzly)

Change-Id: Id6bc10c3e84262c0a9e6160a76af03c0ad363e9c
2016-02-11 10:52:47 +00:00
Jenkins
bf4c26d7ef Merge "Enable in-process func tests to optionally use fast-post" 2016-02-11 08:29:56 +00:00
Jenkins
4322fa61a8 Merge "Script for checking sanity of manpages" 2016-02-11 06:14:13 +00:00
Ondřej Nový
cc8dc88b55 Script for checking sanity of manpages
Change-Id: Ia27b0ecf6a3267eb51f8a6562721dca72f128915
2016-02-10 14:16:56 -08:00
root
bcada66b90 Removed unused parameter in server.py
The variable max_large_object_get_time is no longer used and was
removed to reflect the change.

Change-Id: I43051181dcb38245de6d13fab63876e83f46fc39
Closes-Bug: #1538834
2016-02-10 14:26:10 -06:00
gh159m
b5311f63db Removed default value for log_statsd_host
Multiple files and documents showed that log_statsd_host had
a default value, usually localhost.  This was incorrect, instead
setting a value for log_statsd_host enables statsd logging.

Removed any reference of log_statsd_host having a default value.

Also changed descriptions to show setting a value enables logging.

Change-Id: I3ca5c0e8b8e4981de3aa6db0c476072b5a59723d
Closes-Bug: #1542227
2016-02-10 10:36:59 -06:00
Jenkins
b140d7d8b8 Merge "Changed EC backend from jerasure to liberasurecode in examples and docs" 2016-02-09 08:04:21 +00:00
Ondřej Nový
ae632abbd8 Fixed manpages errors.
account-server.conf.5
105: warning: numeric expression expected (got `)')

container-server.conf.5
111: warning: numeric expression expected (got `)')

object-expirer.conf.5
79: warning: numeric expression expected (got `)')

object-server.conf.5
114: warning: numeric expression expected (got `)')

proxy-server.conf.5
121: warning: numeric expression expected (got `)')
331: warning: numeric expression expected (got `[')
1005: warning: macro `*' not defined

Change-Id: I203dcfde83035e3b1dcb91109b72b5d08bb7840e
2016-02-04 16:20:14 +01:00
venkatamahesh
050e3b35dd Use uppercase 'S' in word "OpenStack"
Change-Id: I4692aa58b5173b1b662d5eee19fac770ae5aaed0
2016-02-04 16:48:13 +05:30
Jenkins
eaf6af3179 Merge "Allow IPv6 addresses/hostnames in StatsD target" 2016-02-04 03:23:01 +00:00