Return-Path: X-Original-To: apmail-deltacloud-dev-archive@www.apache.org Delivered-To: apmail-deltacloud-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 3656C98A9 for ; Thu, 29 Mar 2012 13:10:51 +0000 (UTC) Received: (qmail 22236 invoked by uid 500); 29 Mar 2012 13:10:51 -0000 Delivered-To: apmail-deltacloud-dev-archive@deltacloud.apache.org Received: (qmail 22212 invoked by uid 500); 29 Mar 2012 13:10:51 -0000 Mailing-List: contact dev-help@deltacloud.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@deltacloud.apache.org Delivered-To: mailing list dev@deltacloud.apache.org Received: (qmail 22200 invoked by uid 99); 29 Mar 2012 13:10:51 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 29 Mar 2012 13:10:51 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 29 Mar 2012 13:10:47 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 6CFEC34CA55 for ; Thu, 29 Mar 2012 13:10:26 +0000 (UTC) Date: Thu, 29 Mar 2012 13:10:26 +0000 (UTC) From: "Marios Andreou (Resolved) (JIRA)" To: dev@deltacloud.apache.org Message-ID: <730849305.32349.1333026626527.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <733559702.9782.1332530368948.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Resolved] (DTACLOUD-174) Executing "GET api/buckets/:bucket_id/:blob_id" where blob_id is non-existant returns 200 OK MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/DTACLOUD-174?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Marios Andreou resolved DTACLOUD-174. ------------------------------------- Resolution: Fixed Assignee: Ronelle Landy (was: Marios Andreou) pushed to master: commit a16c34de06776f91fb68cc49e6e1f7d2c815fc01 Author: marios Date: Mon Mar 26 15:07:25 2012 +0300 Fixes DTACLOUD_174: GET on non-existant blob should return 404 (ec2 driver was giving 200OK) https://issues.apache.org/jira/browse/DTACLOUD-174 > Executing "GET api/buckets/:bucket_id/:blob_id" where blob_id is non-existant returns 200 OK > -------------------------------------------------------------------------------------------- > > Key: DTACLOUD-174 > URL: https://issues.apache.org/jira/browse/DTACLOUD-174 > Project: DeltaCloud > Issue Type: Bug > Components: Server > Environment: - Deltacloud git commit version 7e372dfca79c02a799046287e5936129216b781b - branch 'master' of https://git-wip-us.apache.org/repos/asf/deltacloud > - ec2 provider > - Fedora 16, RHEL 6.2 > Reporter: Ronelle Landy > Assignee: Ronelle Landy > Attachments: 0001-Fixes-DTACLOUD_174-GET-on-non-existant-blob-should-r.patch > > > This issue was found by attempting to create a blob using the PUT format, but with empty upload_file. Deltacloud still says blob is created - GET api/buckets/:bucket_id does not return that blob. > (note from Marios - real bug is here) When you use --upload-file with no input, it actually does a GET. GET on a non-existant blob returns 200 OK > curl -H 'content-type: text/html' -H 'X-Deltacloud-Blobmeta-Name:myblob' -H 'X-Deltacloud-Blobmeta-Version:2.4' -H 'X-Deltacloud-Blobmeta-Author:rlandy' -iv --upload-file "" --user "username:password" "http://localhost:3009/api/buckets/bucket-rlandy2/03222012blob7?format=xml" > * About to connect() to localhost port 3009 (#0) > * Trying 127.0.0.1... connected > * Connected to localhost (127.0.0.1) port 3009 (#0) > * Server auth using Basic with user 'AKIAJCBB265A57CGKR2Q' > > GET /api/buckets/bucket-rlandy2/03222012blob7?format=xml HTTP/1.1 > (Note from Marios): HERE...^^^^^^^^^^^^^ > The real bug then is that a GET on a non-existant blob returns 200 OK. This is due to the s3 gem. > > Authorization: Basic QUtJQUpDQkIyNjVBNTdDR0tSMlE6bVJxUG80QzU2NmVwT2F1SXhPNGZhRnNPZGVUeXVzN29PVmRIS2d3NQ== > > User-Agent: curl/7.21.7 (x86_64-redhat-linux-gnu) libcurl/7.21.7 NSS/3.13.1.0 zlib/1.2.5 libidn/1.22 libssh2/1.2.7 > > Host: localhost:3009 > > Accept: */* > > content-type: text/html > > X-Deltacloud-Blobmeta-Name:myblob > > X-Deltacloud-Blobmeta-Version:2.4 > > X-Deltacloud-Blobmeta-Author:rlandy > > > < HTTP/1.1 200 OK > HTTP/1.1 200 OK > < Content-Type: application/xml > Content-Type: application/xml > < ETag: "1e2b9f0b138187d17b3858795ffff479" > ETag: "1e2b9f0b138187d17b3858795ffff479" > < X-Frame-Options: sameorigin > X-Frame-Options: sameorigin > < Server: Apache-Deltacloud/0.5.0 > Server: Apache-Deltacloud/0.5.0 > < Date: Thu, 22 Mar 2012 21:09:07 GMT > Date: Thu, 22 Mar 2012 21:09:07 GMT > < X-Runtime: 0.841249 > X-Runtime: 0.841249 > < X-XSS-Protection: 1; mode=block > X-XSS-Protection: 1; mode=block > < Content-Length: 417 > Content-Length: 417 > < Cache-Control: max-age=0, private, must-revalidate > Cache-Control: max-age=0, private, must-revalidate > < Connection: keep-alive > Connection: keep-alive > < > > > bucket-rlandy2 > > > > > > > > * Connection #0 to host localhost left intact > * Closing connection #0 > Note that 03222012blob7 is not returned here: > [rlandy@localhost server]$ curl -X GET --user "username:password" "http://localhost:3009/api/buckets/bucket-rlandy2?format=xml" > > > bucket-rlandy2 > 6 > > > > > > > > [rlandy@localhost server]$ -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira