190 Commits

Author SHA1 Message Date
Garret Alfert
5378826c6a Also use content checksum for ETag calculation
Timestamp is not enough, as it might be the same
for two consequent PUTs.
2016-03-04 22:17:25 +01:00
Garret Alfert
3590b7dedc Determine correct metadata key for objects in root dir 2016-03-04 20:47:41 +01:00
Garret Alfert
43ff83d26b Don't allow PUTS with Content-Range header 2016-03-04 19:33:00 +01:00
Garret Alfert
fd3293025d ETags are quoted, doh 2016-03-04 19:32:36 +01:00
Garret Alfert
d08bc45489 Don't use or create any directory objects in Swift 2016-03-04 15:33:28 +01:00
Garret Alfert
9b7b224f79 Use more explicit key name for items 2016-03-02 18:06:42 +01:00
Garret Alfert
c2fd9bc6d0 Change Redis metadata key prefix to rs:m 2016-03-02 18:04:38 +01:00
Garret Alfert
88f2dceb27 Use single letters for Redis metadata keys
Saves 16 characters per document object and 10
characters per directory object
2016-03-02 15:00:33 +01:00
Garret Alfert
650da91a1d Shorten Redis metadata keys
Use rsm:<username>:<dir>:i instead of
rs_meta:<username>:<dir>:items
2016-03-02 14:43:28 +01:00
Garret Alfert
067f4a1553 Use shorter Redis key for dir backend config
rsc:db:username instead of rs_config:dir_backend:username
2016-03-02 14:33:48 +01:00
Garret Alfert
ff25b40385 Save last modified timestamp for objects as well 2016-03-02 14:05:53 +01:00
Garret Alfert
c730333143 Don't try to do put or delete requests to root dir in order to update etag 2016-02-02 18:07:12 +01:00
Garret Alfert
409628c9e7 Trying to fix specs when run on Travis 2016-02-01 18:04:35 +01:00
Garret Alfert
7084a50d1b Make dir_empty? method use Redis metadata 2016-01-29 16:45:17 +01:00
Garret Alfert
573dadf365 Respond with 503 when directory backend is locked 2016-01-29 16:18:49 +01:00
Garret Alfert
a4673e9661 Use directory backend config from redis instead of config file 2016-01-29 16:18:09 +01:00
Garret Alfert
16dcc56fba No need to stub has_name_collision? anymore 2016-01-29 15:16:24 +01:00
Garret Alfert
4ca67c7ea9 Do collision detection via Redis metadata 2016-01-28 19:15:50 +01:00
Garret Alfert
15196ca4b9 Check IF_NONE_MATCH header for directory listings 2016-01-23 14:29:37 -05:00
Garret Alfert
bec9f7a6cc Set ETag header for directory listings 2016-01-23 14:29:18 -05:00
Garret Alfert
c676c1a6a8 Add metadata entry for root directory 2016-01-23 14:28:14 -05:00
Garret Alfert
599865cf3f Generate directory listing from Redis metadata 2016-01-23 13:26:38 -05:00
Garret Alfert
f73c286ce9 Purge all keys from redis before every test run 2016-01-23 12:34:08 -05:00
Garret Alfert
25c170021e Delete metadata from Redis when deleting objects 2016-01-22 16:04:28 -05:00
Garret Alfert
02e5d0b5ab Fix relative path in riak specs 2016-01-22 14:49:57 -05:00
Garret Alfert
972378e67f Don't care for order of array when comparing 2016-01-22 14:46:41 -05:00
Garret Alfert
189d04af25 Save list of directory items in redis 2016-01-20 17:27:00 -05:00
Garret Alfert
cd2c0865e8 Save directory metadata in redis (WIP) 2016-01-20 15:53:22 -05:00
Garret Alfert
990ea9cf28 Save object metadata in redis 2016-01-20 15:33:35 -05:00
Garret Alfert
77bd54b009 Move old specs into riak subdir 2016-01-20 15:32:44 -05:00
Greg Karékinian
35c04f85e4 Add a Swift remoteStorage provider 2015-04-29 20:13:04 +02:00
Greg Karékinian
540d9e32d2 Merge branch 'expose_content_length_header' 2015-03-14 16:14:11 +01:00
Greg Karékinian
bbb1bc0af0 Merge branch 'fix_empty_file_response' 2015-03-14 15:48:15 +01:00
Greg Karékinian
30a21db1ad Expose Content-Length header
Refs #50
2015-03-13 11:43:35 +01:00
Greg Karékinian
0f1f445e7f Always cast the Content-Length header into a string
Fixes a crash in Rainbows, when a header is set to a Fixnum/Integer.

Refs #53
2015-03-13 11:22:05 +01:00
Greg Karékinian
3851a88c81 Add a describe block for the public file with content
Also add a comment about why it's hard to check for nil because of Rack.
2015-03-13 10:42:48 +01:00
Greg Karékinian
a15635ce38 Fix a bug when a document has an empty body
Add check on content length for an empty file
2015-03-12 21:51:37 +01:00
247559e563 Add test for GET on empty object (refs #48) 2015-03-03 10:15:53 -04:00
Garret Alfert
8e355ba532 Respond with 409 on naming collisions between documents and folders 2014-09-23 17:59:28 +02:00
Garret Alfert
1603d3d2ff Merge branch 'master' into rs_spec_02
Conflicts:
	lib/remote_storage/riak.rb
	spec/directories_spec.rb
2014-09-23 17:58:21 +02:00
Garret Alfert
a6707dd40d Add spec for unescaped special characters 2014-02-24 20:44:23 +01:00
Garret Alfert
9e6cc6178d Don't choke on colons in directory names (fixes #39) 2014-02-24 17:43:43 +01:00
Garret Alfert
270ac1442e If-None-Match header may contain multiple revisions 2014-01-09 23:51:05 +01:00
Garret Alfert
38e69f1423 Last-Modified header is not needed anymore 2014-01-09 21:00:13 +01:00
Garret Alfert
8073eec851 HEAD requests for directory listings 2014-01-09 20:03:34 +01:00
Garret Alfert
f8b1ad730a HEAD requests for documents 2014-01-09 19:26:36 +01:00
Garret Alfert
6d86fa516a Set Content-Length header for documents on GET 2014-01-08 23:27:07 +01:00
Garret Alfert
75e52f3e9a New directory listing format 2014-01-08 21:41:01 +01:00
Garret Alfert
fd8b2059b2 Value for 'Expires' header needs to be a string 2013-12-09 01:57:26 +01:00
Garret Alfert
4ae4865de5 Set response code for newly created objects to 201 2013-12-08 23:22:36 +01:00