[Walrus] Incorrect response for ranged GET

Bug #729054 reported by Gilles Gaillard
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Eucalyptus
Fix Committed
Undecided
Neil Soman
2.0
In Progress
Undecided
Unassigned

Bug Description

1. As per RFC-2616 14.35.1 when a byte range is submitted in a GET the "last-byte-pos value gives the byte-offset of the last byte in the range". Eucalyptus instead returns one byte less than expected. It seems to me that the issue is in FileSystemStorageManager#sendObject when initializing the ChunkedDataFile (or the compressed one).

2. Still as per the same reference, the server SHOULD return a response with a status of 206 (Partial Content) instead of 200 (OK).

Related branches

Revision history for this message
Gilles Gaillard (gillouxgaillard) wrote :

Also per the same RFC, specifying an incomplete range like:
  Range: bytes=567889-
should be accepted.

Currently it returns a 500 'Internal error' which is reflected in logs by:
14:59:12 [WalrusRESTBinding:New I/O server worker #1-4] ERROR java.lang.ArrayIndexOutOfBoundsException: 1
java.lang.ArrayIndexOutOfBoundsException: 1
 at com.eucalyptus.ws.handlers.WalrusRESTBinding.parseExtendedHeaders(WalrusRESTBinding.java:730)
 at com.eucalyptus.ws.handlers.WalrusRESTBinding.getOperation(WalrusRESTBinding.java:580)
 at com.eucalyptus.ws.handlers.WalrusRESTBinding.bind(WalrusRESTBinding.java:285)
 at com.eucalyptus.ws.handlers.WalrusRESTBinding.incomingMessage(WalrusRESTBinding.java:180)
 at com.eucalyptus.ws.handlers.WalrusRESTBinding.handleUpstream(WalrusRESTBinding.java:158)

Neil Soman (neilsoman)
Changed in eucalyptus:
assignee: nobody → Neil Soman (neilsoman)
Revision history for this message
Neil Soman (neilsoman) wrote :

Thanks for your report! Fixed in revno 1259. Please reopen if this doesn't fix your problem. Thanks.

Changed in eucalyptus:
status: New → Fix Committed
Revision history for this message
Andy Grimm (agrimm) wrote :

This issue is now being tracked upstream at http://eucalyptus.atlassian.net/browse/EUCA-2754

Please watch that issue for further updates.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.