386 Commits

Author SHA1 Message Date
venkatamahesh
21f6fa7172 Change repositories from stackforge to openstack
Change-Id: Id1cecf2e55128494684c7f7bd23600b52fd5b6cb
2015-10-19 23:34:53 +05:30
Jeremy Stanley
94ce66ee88 Update .gitreview for new namespace
Change-Id: Ica3efb65cc4af18c1d73449ccc1c5b6bbf3e75cf
2015-10-17 22:40:40 +00:00
Prashanth Pai
3083d14aff Fix inconsistent data being returned on GET
This is a manual forward-port of the following change merged into
icehouse branch: https://review.openstack.org/215119

When content of an object is modified from filesystem interface, a GET
on the object will return inconsistent or incomplete content because the
content length originally stored as metadata no longer reflects the
actual length of the file after modification.

The complete fix will have two parts:
(1) Return the entire content of object as is to the client
(2) The Etag returned should reflect the actual md5sum of object content

This change only fixes (1) mentioned above. This means, the client will
always get the complete content of the file.

Fix (2) is not part of this change. This means, if content length of the
object remains same even after modification, the Etag returned would be
incorrect. Fixing (2) involves more invasive changes in the code. So
that is deferred for now and will be sent as a separate change later.

Reference:
https://bugs.launchpad.net/swiftonfile/+bug/1416720
https://review.openstack.org/151897

Change-Id: I28d0ec33c59eb520be7d15a60adb968692226e3e
Closes-Bug: #1416720
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-10-01 15:31:39 +05:30
Prashanth Pai
a55740493e Fix object server leaking file descriptors
This is a manual forward-port if the following change in icehouse
branch: https://review.openstack.org/211866

Object server never closes file descriptor when DiskFile.open()
raises an exception. This is fixed by catching exceptions thrown
by code block inside DiskFile.open() and manually closing the
file descriptor.

Change-Id: Ie3e047443f4893e21b9cbdea691867f069363d7e
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-10-01 15:31:39 +05:30
Prashanth Pai
18d039a893 read_metadata() consumers should catch IOError
The xattr module raises IOError which is what the call to
read_metadata() in rmobjdir() should be catching.

Change-Id: I2983ad0be453647f80b862eea93a5fc16fcef04a
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-10-01 15:11:46 +05:30
Thiago da Silva
d792d40bd7 fix requirements.txt
restrict pyeclib version to 1.0.7, similar to swift

Change-Id: Ia69b6e1ac82a60d5cca9bbac8bb355124dc75cd6
Signed-off-by: Thiago da Silva <thiago@redhat.com>
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-10-01 14:59:16 +05:30
Jenkins
8e3b642a40 Merge "Simplify temp file naming convention" 2015-08-05 21:07:57 +00:00
Prashanth Pai
402f2b4954 Fix building of RPMs
* Update MANIFEST.in
* Update spec file
  - Update dependency to openstack-swift-object 2.3.0
  - Update URL to point to stackforge repo
  - Remove unnecessarry dependencies
  - Remove references to glusterfs
* Make makerpm.sh script executable
* Remove .travis.yml (unrelated)
* Remove legacy Glusterfs.py which is no longer used (unrelated)

Reference spec file from upstream openstack-swift:
http://pkgs.fedoraproject.org/cgit/openstack-swift.git/tree/openstack-swift.spec

Change-Id: I4644fa5b258615e0f8c0b3bdc5287fc169388eb2
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-07-15 12:50:49 +05:30
Prashanth Pai
1a6e22ea88 Simplify temp file naming convention
The intent was (and still is) to devise an unique name for the tempfile.
I can't think of any reason why uuid wouldn't work.

Also, added a comment which has a link to the document explaining why
the specific naming convention is used for temp file name.

Change-Id: I5f0d2b631e276c47c88c554485caaec767703695
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-07-10 01:01:50 +00:00
Jenkins
11b61294c2 Merge "Handle REPLICATE requests gracefully" 2015-07-10 00:17:22 +00:00
Prashanth Pai
a39bcbaae2 Remove references to use_put_mount and fs.conf
These are old remnant code that is no longer in use.

Change-Id: Ic0afe1f16884efec49bfa2f64345129e1421daa6
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-07-09 23:58:09 +00:00
Jenkins
4018b3f749 Merge "Rebase to Swift 2.3.0" 2015-07-07 18:37:59 +00:00
Jenkins
780e697e2f Merge "Cleanup exception logging" 2015-07-07 09:54:27 +00:00
Prashanth Pai
b145f9b68d Rebase to Swift 2.3.0
This change does the following:

* Update all functional tests, unit tests and conf files based on
  Swift 2.3.0 release.

* Fix "test_versioning_dlo" test from Swift to be SOF compatible.

* Bump swiftonfile release version to 2.3.0

* Update swiftonfile with DiskFile API changes

Change-Id: I75e322724efa4b946007b6d2786d92f73d5ae313
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-07-06 15:22:10 +05:30
Zandrr
63589a98aa Fix incomplete example command in quick start guide
Change-Id: Ic55d1f62ab2ee783aece5a5850feb90123335bdb
2015-06-16 13:21:19 +00:00
Bill Owen
0d11589042 Cleanup exception logging
Add IOERROR.strerror to exception messages in utils.py
Correct some types in exception messages in fs_utils.py

Change-Id: Iac81860b08daf8cdbb7f8e8950f4ab6104b75bd4
Closes-Bug: #1445237
2015-04-20 05:49:43 -07:00
Prashanth Pai
c6aae2b0cc Allow marker dir objects ending with slash
Allow a slash at the end of object file name but ONLY if the PUT
request also has a "Content-type: application/directory" header.

Change-Id: Ic775de052ee3635e95f5e32ca6e2038909fe1005
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-02-26 12:04:09 +05:30
Prashanth Pai
3c18b83430 Handle REPLICATE requests gracefully
Override Swift's REPLICATE request handler method with a no-op which
returns HTTPNotImplemented (501).

Change-Id: Iaa52ca7e66ddaeda55e73841cd06b64e3e8a3369
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-02-18 15:04:10 +05:30
Prashanth Pai
aa1bfb3e67 Rebase to Swift 2.2.1 release
NOTE:
The previous rebase was to Swift 2.1.0 and this rebase is to
Swift 2.2.1 (first release in kilo series). There was a
Swift 2.2.0 (last release in juno series) release in between.

Change-Id: Ibce2e299935e165db89a91a6fe8c4c5c027db098
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-02-02 11:17:59 +05:30
Jenkins
486668b880 Merge "Remove some dead code" 2015-01-31 13:16:28 +00:00
Bill Owen
9d60237a2c Note limitation of swift geo-replication.
Add note about swift geo-replication not being supported for
Swift on File containers.

Also add reference and links to Swift on File presentation from
Paris summit.

Change-Id: If8b4608d7b20c16b4e8890728eb9714db01becc9
2015-01-30 19:03:08 -07:00
Jenkins
786460d9d1 Merge "Workflow documentation is now in infra-manual" 2015-01-20 19:09:08 +00:00
Prashanth Pai
eb7883dc23 Remove some dead code
Used vulture utility to detect unused code in swiftonfile.
https://pypi.python.org/pypi/vulture

Change-Id: I045f5a96a48d2384718ad0f993540caa3a866309
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2015-01-19 13:03:51 +05:30
Jenkins
b76c95dbcb Merge "Add MANIFEST.in" 2015-01-16 19:59:05 +00:00
Jenkins
dcb19c6e1f Merge "Generalize README by adding references to GPFS." 2015-01-16 19:58:55 +00:00
Bill Owen
2d0db8eb6c Generalize README by adding references to GPFS.
Add references to IBM GPFS to emphasize the SoF is not closely
linked with GlusterFS.

Change-Id: I0fb07cadb256943e2a4c1ac065c11ed9967156d4
2015-01-13 17:38:00 -07:00
Pete Zaitcev
c5984b5dcd Add MANIFEST.in
Current tree does not collect everything available when the usual
"python setup.py sdist" is run. Resulting tarball works, but cannot
be used to build complete RPMs.

Strangely puzzling, adding include_package_data=True does not work.
It simply has no effect. So, we add MANIFEST.in like in the old days.

Since we're at it, add everything else missing, like the README.md.
Stock setuptools in F21 only collects README.txt, but not Markdown.

Change-Id: I9fb89429a8b690fc7e8e128962aeb991a1f760d9
2015-01-09 21:56:59 -07:00
Jeremy Stanley
341048e1c0 Workflow documentation is now in infra-manual
Replace URLs for workflow documentation to appropriate parts of the
OpenStack Project Infrastructure Manual.

Change-Id: Id6a13d0396e16e0e9e1a08f3d7d24566d8ccccb5
2014-12-05 03:30:47 +00:00
Prashanth Pai
b4ee36ef11 Fix bug in object name constraint
SOF can support object names of upto 1024 if it conforms to the
following constraints:

Object names can have forward slashes ('/') in them. Each segment in
between these slashes cannot exceed 255 characters with exception of
the last segment which cannot exceed 221 characters.

This constraint arises from the fact that each segment except the last
one in object name is a directory, the last segment being an actual
file on the filesystem.

Also, restored default constraint values in swift.conf since the SOF
constraints middleware (always in proxy pipeline) will take care of it.

Change-Id: Ia7dc44671a87911c092fecd0344eace92f5c225b
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2014-12-01 13:05:29 +05:30
Prashanth Pai
e87f634b0f doc: Update merge requirements.
Change-Id: Ief6f19b1e28fbfafa3bade8f44faf6b66eea1e92
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2014-10-08 11:15:56 -04:00
Jenkins
3c7efb8bd7 Merge "new constraints middleware" 2014-10-07 21:03:19 +00:00
Thiago da Silva
c0b3d73189 new constraints middleware
Adding a constraints middleware that allows different constraints for a
Swift-on-File storage policy.

Currently, Swift allows only one set of object naming and metadata rules
per cluster. As new storage policies are implemented, it is possible that
different storage back-ends have different set of rules on how objects should
be created for that specific storage system. Swift-on-File has different rules
as objects name are mapped to a POSIX filesystem directory structure.
For example: no names with double slashes or ending with slashes are allowed.

At first a solution was proposed to include a generic patch in the upstream
swift code, but after discussing with the Swift community it became clear that
it would be better to have a global set of constraints that covers the whole
cluster and if a specific storage policy has specific constraints than it
should have its own middleware.
Link to patch for reference: https://review.openstack.org/#/c/113325/

Change-Id: I323ead5d98bf5c087930ccf446d3e8d83075e584
Signed-off-by: Thiago da Silva <thiago@redhat.com>
2014-10-07 16:53:44 -04:00
Jenkins
379915bb71 Merge "Rebase swiftonfile to swift 2.1.0 release" 2014-10-07 19:42:46 +00:00
Prashanth Pai
52e764ecab Rebase swiftonfile to swift 2.1.0 release
Change-Id: I10776fe7d4e3069201775ec6ceae96fd3db32125
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2014-10-07 02:02:01 +05:30
Jenkins
a96ff88cf2 Merge "doc: Update developer documentation" 2014-10-06 15:23:26 +00:00
Prashanth Pai
a765973600 doc: Update developer documentation
Change-Id: I531bfc11c93a0e0b44e421e443b2fc3697721195
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2014-10-01 13:33:53 -04:00
Bill Owen
d187234c11 Rename exceptions to use SwiftOnFile name.
Rename exceptions from GlusterFS to SwiftOnFile names.

Change-Id: Idddc16777cd08e66ce6634a65e4199db1f67e20a
2014-09-29 22:32:47 -07:00
Prashanth Pai
d8765aac78 Add .gitreview file
Change-Id: I29bc82a2ff86a1f986a5512cda792187bae31f7e
Signed-off-by: Prashanth Pai <ppai@redhat.com>
2014-09-22 12:19:08 +05:30
Thiago da Silva
2d9033234b Merge pull request #34 from thiagol11/update_readme
update the README file
2014-09-05 09:51:37 -04:00
Thiago da Silva
b27df0deaa update the README file
changing the README file to clarify swift-on-file operations
and update with latest code changes

Signed-off-by: Thiago da Silva <thiago@redhat.com>
2014-08-28 14:01:37 -04:00
Thiago da Silva
cd0faa4d7b Merge pull request #33 from thiagol11/release2.0
Updating SwiftOnFile version to release 2.0
2014-08-18 14:18:09 -04:00
Thiago da Silva
f482f2fdf4 Updating SwiftOnFile version to release 2.0
Updated sof version and tox swift dependency to
release 2.0.
Also, made some documentation changes to the object-server
configuration sample file to point out that volume must
mounted before starting sof object-server.

Signed-off-by: Thiago da Silva <thiago@redhat.com>
2014-08-18 13:20:15 -04:00
Thiago da Silva
befd78df91 Merge pull request #30 from prashanthpai/add-func-test
Add a swiftonfile specific functional test
2014-08-15 10:13:56 -04:00
Prashanth Pai
85bd7d622e Add a swiftonfile specific functional test
Test whether files created over mountpoint can be accessed over
Swift using GET.

Signed-off-by: Prashanth Pai <ppai@redhat.com>
2014-08-07 12:54:16 +05:30
Thiago da Silva
a123c73aa0 Update README.md 2014-07-31 13:26:56 -04:00
Thiago da Silva
c01b3cbcbf Update README.md 2014-07-31 13:25:33 -04:00
Thiago da Silva
c8cd4354b7 Update README.md 2014-07-31 13:24:54 -04:00
Thiago da Silva
12c675ab27 Update dev_guide.md 2014-07-31 13:13:00 -04:00
Thiago da Silva
c70faa4e27 Update quick_start_guide.md 2014-07-31 10:40:14 -04:00
Thiago da Silva
91b8b2cf7a Update quick_start_guide.md 2014-07-31 10:37:54 -04:00