Test compares cluster info to hardcoded expected data and wasn't
sorting the two sets of things being compared leading to some
sporadic unit test failures.
On older versions of python 2.6, exceptions would be spewed to the error
log whenever a service would stop. This gets magnified by the
container-updater which seems to do it with every pass. This catches
and squelches the error.
The only explicit use of Python threading is found in the
testFileSizeLimit test. Using eventlet seems a bit easier to follow,
accomplishing the same goal, and does not constrain us to a
multi-threaded environment.
The chunks() and timeout() module level functions are only used by one
test each, so we just move them to those tests to indicate they are not
used globally.
Add test to check that only the expected keys are
reported by proxy in /info, and add comments to
raise awareness that default constraints will be
automatically published by proxy in response to /info
requests.
This file is normally updated in the standard "update from
global requirements" patch, but since those contain other
changes we don't want, the setup.py file never gets updated.
This patch updates setup.py to bring it in line with the
standard global requirements way of doing things without also
updating [test-]requirements.txt
Two of the default constraints, max_header_size and
max_meta_overall_size, don't get registered for the
/info response by the proxy server.
Rather than adding them individually to the proxy's
register_swift_info call, this patch proposes to
register all the constraints for /info at once
using the constraints.EFFECTIVE_CONSTRAINTS dict.
Any future additions to default constraints will
then be automatically included in /info.
commit d32dc8d49c19de8b1264cae23b82b3ffd9707454
Author: Greg Lange <email address hidden>
Date: Wed Mar 26 22:55:55 2014 +0000
Unify backend logging
Make account, object, and container servers construct log lines using the
same utility function so they will produce identically formatted lines.
This change reorders the fields logged for the account server.
This change also adds the "additional info" field to the two servers that
didn't log that field. This makes the log lines identical across all 3
servers. If people don't like that, I can take that out. I think it makes
the documentation, parsing of the log lines, and the code a tad cleaner.
Support for content-length in the upload object method for
internal client.
Internal client uses 'chunked' transfer encoding in it's
upload_object method. If content-length is known in advance,
internal_client should allowed to use content length in the
upload_object method and not the chunked method.
commit b9b5fef89af51c66905de33e2436c063f4b09d36
Author: James Page <email address hidden>
Date: Sat Apr 5 09:38:12 2014 +0100
Set permissions on generated ring files
The use of NamedTemporaryFile creates rings with permissions 0600;
however most installs probably generate the rings as root but the
swift-proxy runs as user swift.
Set the permissions on the generated ring to 0644 prior to rename so
that the swift user can read the rings.
It seems that the test_connect_put_timeout() test does not always fail
when it is expected. Sometimes, not very often, the attempt to connect
succeeds, resulting in a failed test.
This might be because the fake-connection infrastructure uses a
sleep(0.1) and the test uses a connect timeout of 0.1. There might be a
case where the two values result in the exact time where the entries
happen to be added in the wrong order such that the sleep() completes
first before the connect timeout fires, where the connect completes
successfully.
commit 62a1e7e0593723ff19a83c1533b02f6f444f6942
Author: Samuel Merritt <email address hidden>
Date: Tue Mar 4 11:52:48 2014 -0800
Support If-[Un]Modified-Since for object HEAD
We already supported it for object GET requests, but not for
HEAD. This lets clients keep metadata up-to-date without having to
either fetch the whole object when it's changed or do their own date
parsing. They can just treat Last-Modified as opaque and update their
idea of metadata when they get a 200.
Reviewed: https:/ /review. openstack. org/88359 /git.openstack. org/cgit/ openstack/ swift/commit/ ?id=282548d5381 53fa2fae1d2a4ec 19d75dc2a41028
Committed: https:/
Submitter: Jenkins
Branch: feature/ec
commit 856c15539a958da be3b8a1f22d3050 48ca39de9a
Author: Paul Luse <email address hidden>
Date: Mon Apr 14 15:19:22 2014 -0700
Fix testcase test_print_ db_info_ metadata( )
Test compares cluster info to hardcoded expected data and wasn't
sorting the two sets of things being compared leading to some
sporadic unit test failures.
Change-Id: I3ef98260a62c15 d06ba8cc196196d 4e90abca3f0
commit 67fff5b2973f5ca 12316041664eddf 3e8ece45be
Author: Madhuri Kumari <email address hidden>
Date: Fri Apr 11 11:53:48 2014 +0530
Print 'Container Count' in data base info
Currently, 'Container Count' was missing in data base info.
So this patch will help printing 'Container Count' also.
Change-Id: I1ca80ee79e71b0 86b30fd2d1ab024 ea1cfb324f5
commit deb0dfd090cee2f eef664bdd444919 4c274d830e
Author: Peter Portante <email address hidden>
Date: Thu Apr 10 14:36:43 2014 -0400
Add includes of referenced SAIO bin scripts
Change-Id: I6810e69a757336 a3aed0a38146c27 f270fe2dde1
commit 2c2ede22338d6ca 9637233076157f1 d26248fbf1
Author: Chuck Thier <email address hidden>
Date: Thu Apr 10 18:59:01 2014 +0000
Fix logging issue when services stop on py26
On older versions of python 2.6, exceptions would be spewed to the error updater which seems to do it with every pass. This catches
log whenever a service would stop. This gets magnified by the
container-
and squelches the error.
Change-Id: I128c09c240e768 e8195af1f6fe79b 10d4e432471
Closes-Bug: #1306027
commit 5ff6a4d5d6cdbf3 9ba9f6d5d416cdd 1c6c6a52ac
Author: Peter Portante <email address hidden>
Date: Mon Apr 7 13:01:44 2014 -0400
Use eventlet instead of threading for timeout
The only explicit use of Python threading is found in the eLimit test. Using eventlet seems a bit easier to follow,
testFileSiz
accomplishing the same goal, and does not constrain us to a
multi-threaded environment.
The chunks() and timeout() module level functions are only used by one
test each, so we just move them to those tests to indicate they are not
used globally.
Change-Id: I50b9fb798fbfd1 d552b3c3f90309f 6b86da34853
commit 58fe2f256fccc14 f5078e9fde9b9f7 b2219a06e5
Author: anc <email address hidden>
Date: Tue Apr 8 18:44:06 2014 +0100
Add tests and comments re constraints in /info
Add test to check that only the expected keys are
reported by proxy in /info, and add comments to
raise awareness that default constraints will be
automatically published by proxy in response to /info
requests.
Change-Id: Ia5f6339b06cdc2 e1dc960d1f75562 a2505530202
commit c2744caac43586b 745c43c37a9c314 83f7a126fc
Author: Samuel Merritt <email address hidden>
Date: Tue Apr 8 11:44:58 2014 -0700
Fix deprecation warning
Accessing BaseException. message spews a warning; we can get the same
information with str(err), which does not spew.
Change-Id: I67648d53d25522 be074a78c44b3ce 97dc27d1f07
commit d47a582e749d3a6 1071ff249175d67 e37bef7e6c
Author: John Dickinson <email address hidden>
Date: Tue Apr 8 10:26:40 2014 -0700
update setup.py with pbr version
This file is normally updated in the standard "update from
global requirements" patch, but since those contain other
changes we don't want, the setup.py file never gets updated.
This patch updates setup.py to bring it in line with the requirements. txt
standard global requirements way of doing things without also
updating [test-]
Change-Id: Id0e4f8e17dd4c7 14b4d2dd7598543 1a9e12e6a4f
commit 677ee3c931b5d30 7e44416b4312074 95435bf402
Author: anc <email address hidden>
Date: Mon Apr 7 18:42:50 2014 +0100
Add missing constraints to /info
Two of the default constraints, max_header_size and meta_overall_ size, don't get registered for the
max_
/info response by the proxy server.
Rather than adding them individually to the proxy's swift_info call, this patch proposes to EFFECTIVE_ CONSTRAINTS dict.
register_
register all the constraints for /info at once
using the constraints.
Any future additions to default constraints will
then be automatically included in /info.
Change-Id: I5c10d4c8eda90b a94745b6f89df85 aafbb50f8ef
commit d32dc8d49c19de8 b1264cae23b82b3 ffd9707454
Author: Greg Lange <email address hidden>
Date: Wed Mar 26 22:55:55 2014 +0000
Unify backend logging
Make account, object, and container servers construct log lines using the
same utility function so they will produce identically formatted lines.
This change reorders the fields logged for the account server.
This change also adds the "additional info" field to the two servers that
didn't log that field. This makes the log lines identical across all 3
servers. If people don't like that, I can take that out. I think it makes
the documentation, parsing of the log lines, and the code a tad cleaner.
DocImpact
Change-Id: I268dc0df9dd07a fa5382592a28ea3 7b96c6c2f44
Closes-Bug: 1280955
commit b67a4b993815f18 30b59054ae0d08a 468044a53e
Author: Gil Vernik <email address hidden>
Date: Mon Apr 7 08:44:54 2014 +0300
Support for content-length in the upload object method for
internal client.
Internal client uses 'chunked' transfer encoding in it's
upload_object method. If content-length is known in advance,
internal_client should allowed to use content length in the
upload_object method and not the chunked method.
Change-Id: I68d2ebde78e01f a16b7187a2f045e a20f4310722
commit b9b5fef89af51c6 6905de33e2436c0 63f4b09d36
Author: James Page <email address hidden>
Date: Sat Apr 5 09:38:12 2014 +0100
Set permissions on generated ring files
The use of NamedTemporaryFile creates rings with permissions 0600;
however most installs probably generate the rings as root but the
swift-proxy runs as user swift.
Set the permissions on the generated ring to 0644 prior to rename so
that the swift user can read the rings.
Change-Id: Ia511931f471c5c 9840012c3a75b89 c1f35b1b245
Closes-Bug: #1302700
commit 9d0067a0f546ce8 a0fddb257655f29 44c05e35e6
Author: Peter Portante <email address hidden>
Date: Fri Apr 4 15:26:32 2014 -0400
Attempt to ensure connect always timesout
It seems that the test_connect_ put_timeout( ) test does not always fail
when it is expected. Sometimes, not very often, the attempt to connect
succeeds, resulting in a failed test.
This might be because the fake-connection infrastructure uses a
sleep(0.1) and the test uses a connect timeout of 0.1. There might be a
case where the two values result in the exact time where the entries
happen to be added in the wrong order such that the sleep() completes
first before the connect timeout fires, where the connect completes
successfully.
Closes bug 1302781
Change-Id: Ie23e40cf294170 eccdf0713e313f9 a31a92f9071
commit f63b37572df9188 f2fc753c06f3248 8a2b2f59a9
Author: Peter Portante <email address hidden>
Date: Tue Apr 1 22:56:43 2014 -0400
Update callback with proper bytes transferred
The first set of bytes transferred was being dropped.
Change-Id: I8e055190d04af1 718c5e88bf5e8c4 4fde6794c74
commit 62a1e7e0593723f f19a83c1533b02f 6f444f6942
Author: Samuel Merritt <email address hidden>
Date: Tue Mar 4 11:52:48 2014 -0800
Support If-[Un] Modified- Since for object HEAD
We already supported it for object GET requests, but not for
HEAD. This lets clients keep metadata up-to-date without having to
either fetch the whole object when it's changed or do their own date
parsing. They can just treat Last-Modified as opaque and update their
idea of metadata when they get a 200.
Change-Id: Iff25d8989a93d6 51fd2c327e1e580 36e79e1bde1