CHAPTER4-1CiscoCloudObjectStorageRelease2.
1.
1APIGuide4SwiftAPIThischapterdescribesthesubsetoftheOpenStackSwiftAPIthatisimplementedforCOS.
TheSwiftAPIusestheStorageFQDNthatisassignedtotheCOScluster.
NoteTheCOSclusterisassignedanAuthenticationFQDN(usedwiththeSwauthAPI)andaStorageFQDN(usedwiththeSwiftAPI).
CurrentlytheAuthenticationFQDNandtheStorageFQDNmustbethesame,forexample,auth01.
cos.
acme.
com.
ListingContainersToretrievealistofexistingstoragecontainers,usethefollowingHTTPGETrequest:NoteTomakethisrequest,youmustbeanaccountadminorareselleradmin.
GET/v1/[=[&=]]HTTP/1.
1ThenamesofthecontainersinthelistaresortedbasedonabinarycomparisonoftheUTF-8encodedcontainernames.
RequiredRequestHeaderX-Auth-Token:OptionalQueryParametersThefollowingparameterscanbeusedinthequery:limit—Specifiesthemaximumnumberofresultstoberetrieved.
marker—RetrievescontainernameswhosecharactershaveagreaterUnicodealphabeticalvaluethanthoseofthespecifiedstring.
end_marker—RetrievescontainernameswhosecharactershavealowerUnicodealphabeticalvaluethanthoseofthespecifiedstring.
prefix—Retrievescontainernamesbeginningwiththespecifiedcharacters.
4-2CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIListingObjectsdelimiter—Retrievescontainernamesthatdonothavethespecifiedcharacter,exceptintheprefix,ifany.
format—Specifieseitherjsonorxmlastheformatoftheserializedresponse.
ListingObjectsTolisttheobjectsinthestoragecontainer,usethefollowingHTTPGETrequest:NoteTomakethisrequest,youmustbeanaccountadministratororCOSreseller-administrator.
Or,ifaread-ACLhasbeenspecifiedforacontainer,eitheryoumusthavebeenassignedarolelistedintheACL,or'*'mustbelistedasarole,permittinganonymousaccess.
GET/v1//[=[&=]]HTTP/1.
1ThenamesoftheobjectsinthelistaresortedbasedonabinarycomparisonoftheUTF-8encodedobjectnames.
OptionalQueryParametersThefollowingparameterscanbeusedinthequery:limit—Specifiesthemaximumnumberofresultstoberetrieved.
marker—RetrievesobjectnameswhosecharactershaveagreaterUnicodealphabeticalvaluethanthoseofthespecifiedstring.
end_marker—RetrievesobjectnameswhosecharactershavealowerUnicodealphabeticalvaluethanthoseofthespecifiedstring.
prefix—Retrievesobjectnamesbeginningwiththespecifiedcharacters.
delimiter—Retrievesobjectnamesthatdonothavethespecifiedcharacter,exceptintheprefix,ifany.
path—Retrievesnamesofobjectsnestedinthespecifiedpath.
format—Specifieseitherjsonorxmlastheformatoftheserializedresponse.
NoteIfaresponseformatisnotspecifiedasaqueryparameter,alistofobjectnamesisreturnedintheresponsebody,onenameperline.
ResponseStatusCodesTheresponsestatuscodeisoneofthefollowing:4-3CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPICreatingaContainer2xx—indicatesasuccessfulexecutionoftherequest.
204(NoContent)—indicatesthateitherthecontainerisempty,ornoneoftheobjectsinthecontainermatchthequeryparametersspecifiedintherequest.
CreatingaContainerTocreateastoragecontainer,usethefollowingHTTPPUTrequest:NoteTomakethisrequest,youmustbeanaccountadmin,aCOSreselleradminorthesuperadmin.
PUT/v1//HTTP/1.
1Thenameofthecontainermustadheretothefollowingrestrictions:Thenamecannotincludetheforwardslash(/)characterortheencodedforwardslashcharacter(%2For%2f).
Thenameshouldnotexceed256byteswhenitisencodedinURL.
RequiredRequestHeaderX-Auth-Token:OptionalRequestHeadersX-Container-Read:X-Container-Write:AssigningCustomAttributesToassigncustomattributestoastoragecontainer,includeadditionalHTTPheadersintheHTTPPUTrequestshownabove.
Theadditionalheadersshouldbeofthefollowingform:X-Container-Meta-:ResponseStatusCodesTheresponsestatuscodeisoneofthefollowing:201(Created)—Thecontainerwascreated.
202(Accepted)—Thecontaineralreadyexists.
400(BadRequest)—Invalidcontainername.
401(Unauthorized)—Theusertokenismissingorinvalid.
403(Forbidden)—Theuserdoesnothavepermissiontocreatethecontainer.
404(NotFound)—ThestorageURLreferencesanon-existentaccount.
4-4CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIDeletingaContainerDeletingaContainerTopermanentlyremoveastoragecontainer,usethefollowingHTTPDELETErequest:NoteTomakethisrequest,youmustbeanaccountadmin,areselleradmin,orthesuperadmin.
DELETE/v1//HTTP/1.
NoteOnlyemptystoragecontainerscanbedeleted.
RequiredRequestHeaderX-Auth-Token:ResponseStatusCodesTheresponsestatuscodeisoneofthefollowing:204(NoContent)—Thecontainerwasdeleted.
400(BadRequest)—Invalidcontainername.
401(Unauthorized)—Theusertokenismissingorinvalid.
403(Forbidden)—Theuserdoesnothavepermissiontodeletethecontainer.
404(NotFound)—ThestorageURLreferencesanon-existentaccount.
409(Conflict)—Thecontainerisnotempty.
RetrievinganObjectToretrievethedataofanobject,usethefollowingHTTPGETrequest:NoteTomakethisrequest,youmustbeanaccountadminorCOSreseller-admin;orifaread-ACLhasbeenspecifiedforthecontainer,eitheryouareassignedarolelistedintheACL,or*isspecifiedasarole,permittinganonymousaccess.
GET/v1///HTTP/1.
1NoteYoumayretrievedatafromanobjectwhileitisbeingcreated.
Ifyoudo,theresponsewillhavetheX-Object-Is-Dynamic:yesheader.
RequiredRequestHeaderX-Auth-Token:4-5CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIRetrievinganObjectNoteIfthecontainerread-ACLpermitsanonymousaccess,thisheaderisnotrequired.
OptionalRequestHeadersX-Follow-Redirect:true–Iftherequesthasthisheader,theCOSnodemayrespondwitha307(TemporaryRedirect)codeandincludeaLocationresponseheaderhavingtheURLatwhichtheclientshouldretrytherequest.
–Iftherequestdoesnothavethisheader,orthevalueoftheheaderisnottrue,theCOSnodereceivingtherequestwillrespondwiththerequestedobject.
NoteTheX-Follow-RedirectrequestheaderisaCOSextension.
X-Transfer-Rate:–Thisheaderspecifiesatransferrateindecimalbitspersecond.
–Validrangeofvaluesforthisheaderis400000to50000000,thatis,400Kbpsto50Mbps.
–Iftheheaderisnotincluded,dataistransferredatthebest-effortratethatdoesnotdelayothertransferswhichwererequestedalongwithanX-Transfer-Rateheader.
–Atransferrateof0isvalidandindicatesabest-efforttransferofdata.
NoteTheX-Transfer-RaterequestheaderisaCOSextension.
X-Transfer-Delay:–Thisheaderspecifiesasigneddelayinmilliseconds.
–Ifthedelayispositive,COSwaitsforthetimeintervalspecifiedbeforestartingthetransferofobjectdataattherequestedtransferrate.
Thepositivedelaycanhaveamaximumvalueof30seconds.
–AnegativedelayindicatesthattheclientwantstouseanelasticitybufferandintendstotransmitdatafromthepartiallyfullbufferthatreceivesdatafromCOSattherequestedtransferrate.
Inthiscase,COSstartstransferringthedataassoonastheretrieverequestisreceived,andattemptstosenddataataratehigherthantherequestedrate.
COS,inessence,triestomatchtheamountofdatathatwouldhavebeensenttotheclientifthedatatransferhadbeeninitiated"delay"secondsbeforethereceiptoftherequest.
Thenegativedelaycanhavemaximummagnitudeoffourseconds.
NoteTheX-Transfer-DelayrequestheaderisaCOSextension.
Range:bytes=–Torequestthetransferofspecificportionsoftheobjectdata,inaccordancewiththespecificationsinsection14.
35ofRFC2616,includethisheader.
–Onlybyte-rangesaresupported.
–Multiplebyterangesaresupported.
4-6CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIRetrievinganObject–Iftherangedidnotincludetheentireobject,aresponsestatuscodeof206(PartialContent)isreturnedbyCOS.
–ThePartialContentresponsetoarequestformultiplenon-overlappingrangesofdatacontainsmultiplepartsinthemessagebody.
If-Match:ETag–TheobjectdataisretrievedonlyiftheclientspecifiedETagvaluematchestheETagofthecontent.
Else,412(PreconditionFailed)isreturned.
If-None-Match:ETag–304(NotModified)isreturnediftheclientspecifiedETagvaluematchestheETagofthecontent,indicatingtotheclientthattheobjectcachedbyithasnotbeenmodifiedsince.
If-Modified-Since:time–304(NotModified)isreturnediftheclientspecifiedtimeisequaltoorlaterthanthelastmodifiedtimeoftheobject.
If-Unmodified-Since:time–Theobjectdataisretrievedonlyiftheclientspecifiedtimeisequaltoorlaterthanthelastmodifiedtimeoftheobject.
Else,412(PreconditionFailed)isreturned.
ResponseStatusCodesAresponsestatuscodeof2xxindicatessuccessfulcompletionoftherequest.
ResponseHeadersTheresponsewillincludeoneofthefollowingheaders:LastModified—Atime-stampofwhentheobjectwascreatedormodified.
ETag—ThehexadecimalrepresentationoftheMD5hashoftheobjectdata.
Content-Type—Thecontenttypeassociatedwiththeobjectwhenitwascreated.
Content-Length—Thenumberofbytesintheobject.
X-Object-Goid—TheglobalobjectidentifierassignedbyCOSwhentheobjectwascreated.
NoteTheX-Object-GoidresponseheaderisaCOSextension.
X-Object-Meta-*—Customobjectattributesoftheobject.
X-Object-Is-Dynamic:yes—Theobjectbeingretrievedisbeingextended.
Thisoccurswhenyouretrieveobjectdatawhileobjectcreationisinprogress.
Sucharetrievalofthedataisusefulwhenalargeobjectisbeingcreatedandyouwanttoaccessthedatathathasbeenstored,evenasmoredataisbeingappendedtotheobject.
ThisresponseheaderisaCOSextension.
NoteTheX-Object-Is-DynamicresponseheaderisaCOSextension.
4-7CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPICreatingorUpdatingAnObjectCreatingorUpdatingAnObjectTocreateorupdateanobject,thatis,towriteoroverwriteanobject'scontentandmetadata,usethefollowingHTTPPUTrequest:PUT/v1///HTTP/1.
1RequiredRequestHeadersX-Auth-Token:NoteThisheadermaybeexcludedifthecontainerwriteACLpermitsanonymousaccess.
Content-Type–Ifthisheaderisnotincluded,thesystemwillattempttoguessthetypeofthecontentbasedontheobject'sname/metadata.
Ifthesystemisunsuccessful,theContent-Typeissettothedefaultapplication/octet-streamvalue.
Content-Length/Transfer-Encoding:chunked–EitheravalidContent-Lengthheader,statingthesizeoftheobject,oraTransfer-Encoding:chunkedheader,indicatingthatthedatalengthisencodedin-lineatthestartofeachchunkoftheobjectdatasentintherequest,mustbeincluded.
OptionalRequestHeadersETag–TherequestmayincludethisheaderwiththevaluesettothehexadecimalrepresentationoftheMD5hashoftheobjectdata.
–IftheETagvaluedoesnotmatchMD5hashcomputedbyCOS,a422(UnprocessableEntity)responsestatuscodeisreturned.
X-Object-Meta-:–Includethisheadertosetcustomattributesforanobject.
X-Follow-Redirect:true–Ifthisheaderisincluded,theCOSnodemayrespondwithastatuscodeof307(TemporaryRedirect)andincludeaLocationresponseheaderindicatingtheURLtowhichtheclientshouldaddresstherequest.
–Ifthisheaderisabsent,orthevalueoftheheaderisnottrue,theCOSnodereceivingtherequestwillperformthenecessaryoperation.
NoteTheX-Follow-RedirectrequestheaderisaCOSextension.
Expect:100-Continue–Itisrecommendedthatyouincludethisheaderintheinitialrequestandomitobjectcontentfromthebodyoftherequest.
4-8CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIDeletinganObject–ThereceivingCOSnodewillrespondwitheithera100(Continue)statuscode,a307(TemporaryRedirect)statuscode,oranerrorstatuscode.
–Ifthe100(Continue)statuscodeisreceived,repeattherequestalongwiththeobjectcontentinthebody.
ResponseStatusCodesTheresponsewillincludeoneofthefollowingheaders:2xx—IndicatesthesuccessfulcompletionoftheHTTPPUTrequest.
5xx—IndicatesfailureoftheHTTPPUTrequest.
ResponseHeadersTheresponsewillincludeoneofthefollowingheaders:LastModified—Atime-stampofwhentheobjectwascreatedorupdated.
ETag—AhexadecimalrepresentationoftheMD5hashoftheobjectdata.
DeletinganObjectTopermanentlyremoveanobject,usethefollowingHTTPDELETErequest:NoteTomakethisrequest,oneofthefollowingmustbetrue:YouareanaccountadminoraCOSreselleradmin.
Ifawrite-ACLhasbeenspecifiedforthecontainer,eitheryouareassignedarolelistedintheACL,ortherole*isincludedintheACL,permittinganonymousaccess.
DELETE/v1///HTTP/1.
1Deletinganobjectremovesboththeobjectdataandmetadata.
Anysubsequentoperationsattemptedontheobjectwillreturna404(NotFound)responsestatuscode.
4-9CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPICreatingorUpdatingContainerMetadataRequiredRequestHeaderNoteIfthecontainerwrite-ACLpermitsanonymousaccess,thisheaderisnotrequired.
X-Auth-Token:ResponseStatusCode204(NoContent)—Indicatestheobjecthasbeendeleted.
CreatingorUpdatingContainerMetadataTocreateorupdatecustomcontainerattributes,usethefollowingHTTPPOSTrequest:NoteTomakethisrequest,youmustbeanaccountadminoraCOSreselleradmin.
POST/v1//HTTP/1.
1TheattributesarespecifiedinHTTPheadersincludedintheHTTPPOSTrequest.
Iftheattributeexists,itsvaluewillbeoverwritten.
Else,anewattributeiscreated.
RequiredRequestHeaderX-Auth-Token:X-Container-Meta-:ResponseStatusCodeTheresponsestatuscodeisoneofthefollowing:204(NoContent)—ThePOSToperationsucceeded400(BadRequest)—ThePOSTrequestisnotvalid401(Unauthorized)—Theusertokenismissingorinvalid403(Forbidden)—Theuserdoesnothavepermissiontomodifythecontainerattributes404(NotFound)—ThestorageURLreferencesanon-existentaccountorcontainer5xx—InternalServerError4-10CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIRetrievingContainerMetadataRetrievingContainerMetadataToretrieveacontainer'smetadatatolearnitsstatus,usethefollowingHTTPHEADrequest:NoteTomakethisrequest,youmustbeanaccountadminoraCOSreselleradmin.
Or,ifaread-ACLhasbeenspecifiedforthecontainer,youmustbeassignedarolelistedintheACL.
Or,the'*'rolemustbeincludedintheACL,permittinganonymousaccess.
HEAD/v1//HTTP/1.
1Thisrequestcanbeusedagainstacontainertodeterminethenumberofobjects,andthetotalbytesizeofallobjectsstoredinthecontainer.
RequiredRequestHeaderNoteIfthecontainerread-ACLpermitsanonymousaccess,thisheaderisnotrequired.
X-Auth-Token:ResponseStatusCodeTheresponsestatuscodeisoneofthefollowing:2xx(Success)—TheHEADoperationsucceeded400(BadRequest)—ThePOSTrequestisnotvalid401(Unauthorized)—Theusertokenismissingorinvalid403(Forbidden)—Theuserdoesnothavepermissiontomodifythecontainerattributes404(NotFound)—ThestorageURLreferencesanon-existentaccountorcontainer5xx—InternalServerErrorResponseHeadersX-Container-Object-Count–Thevalueofthisheaderisthenumberofobjectsinthecontainer.
X-Container-Bytes-Used–Thevalueofthisheaderisthetotalbytesizeofalltheobjectsinthecontainer.
X-Container-Meta-:–Thisheaderreturnsthecustomattributesofthecontainer.
4-11CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIDeletingContainerMetadataDeletingContainerMetadataTodeletecustomcontainerattributes,usethefollowingHTTPPOSTrequest:NoteTomakethisrequest,youmustbeanaccountadminorareselleradmin.
POST/v1//HTTP/1.
1RequiredRequestHeadersX-Auth-Token:X-Container-Meta-–Anemptyheaderofthistypewithouttheattributevaluecanbeusedtodeletethecustomattributenamedintheheader.
X-Remove-Container-Meta-:–Alternatively,aheaderofthistypecanbeusedtodeletethecustomattributenamedintheheader.
–Thearbitraryattributevalueisignoredbythesystem.
ResponseStatusCodeTheresponsestatuscodeisoneofthefollowing:204(NoContent)—ThePOSToperationsucceeded400(BadRequest)—ThePOSTrequestisnotvalid401(Unauthorized)—Theusertokenismissingorinvalid403(Forbidden)—Theuserdoesnothavepermissiontomodifythecontainerattributes404(NotFound)—ThestorageURLreferencesanon-existentaccountorcontainer5XX—InternalServerErrorCreatingorUpdatingObjectMetadataTocreateorupdatecustomobjectattributes,usethefollowingHTTPPOSTrequest:NoteTomakethisrequest,youmustbeanaccountadminoraCOSreselleradmin.
Or,ifawrite-ACLhasbeenspecifiedforthecontainer,youmustbeassignedarolelistedintheACL.
Or,the'*'rolemustbeincludedintheACL,permittinganonymousaccess.
POST/v1///HTTP/1.
14-12CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIRetrievingObjectMetadataAssigningcustomattributestoobjectsenablesyoutobettercategorizetheobjects.
RequiredRequestHeaderX-Auth-Token:NoteIfthecontainerwrite-ACLpermitsanonymousaccess,thisheaderisnotrequired.
X-Object-Meta-:–Iftheattributeexists,itsvalueisupdatedtothatspecifiedintheheader.
Else,theattributeiscreated.
ResponseStatusCodeTheresponsestatuscodeisoneofthefollowing:204(NoContent)—ThePOSToperationsucceeded400(BadRequest)—ThePOSTrequestisnotvalid401(Unauthorized)—Theusertokenismissingorinvalid403(Forbidden)—Theuserdoesnothavepermissiontomodifythecontainerattributes404(NotFound)—ThestorageURLreferencesanon-existentaccountorcontainer5XX—InternalServerErrorRetrievingObjectMetadataToretrieveanobject'smetadata,includingitscustomattributes,usethefollowingHTTPHEADrequest:NoteTomakethisrequest,youmustbeanaccountadminoraCOSreselleradmin.
Or,ifaread-ACLhasbeenspecifiedforthecontainer,youmustbeassignedarolelistedintheACL,andtheReferrerheaderintherequestmustmatchtheACLreferrerpattern.
Or,the'*'rolemustbeincludedintheACL,permittinganonymousaccess.
HEAD/v1///HTTP/1.
RequiredRequestHeaderNoteIfthecontainerread-ACLpermitsanonymousaccess,thisheaderisnotrequired.
X-Auth-Token:ResponseStatusCodeTheresponsestatuscodeisoneofthefollowing:4-13CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIDeletingObjectMetadata2xx(Success)—TheHEADoperationsucceeded400(BadRequest)—TheHEADoperationisnotvalid401(Unauthorized)—Theusertokenismissingorinvalid403(Forbidden)—Theuserdoesnothavepermissiontomodifythecontainerattributes404(NotFound)—ThestorageURLreferencesanon-existentaccountorcontainer5xx—InternalServerErrorResponseHeadersLastModified—atime-stampofwhentheobjectwascreatedormodified.
ETag—thehexadecimalrepresentationoftheMD5hashoftheobjectdata.
Content-Type—thecontenttypeassociatedwiththeobjectwhenitwascreated.
Content-Length—thenumberofbytesintheobject.
X-Object-Meta-:—customobjectattributes,ifany.
DeletingObjectMetadataTodeletecustomobjectattributes,usethefollowingHTTPPOSTrequest:NoteTomakethisrequest,youmustbeanaccountadminoraCOSreselleradmin.
Or,ifawrite-ACLhasbeenspecifiedforthecontainer,youmustbeassignedarolelistedintheACL.
Or,the'*'rolemustbeincludedintheACL,permittinganonymousaccess.
POST/v1/HTTP/1.
1RequiredRequestHeadersX-Auth-Token:X-Object-Meta-:–Anemptyheaderofthistypewithouttheattributevaluecanbeusedtodeletethecustomattributenamedintheheader.
X-Remove-Object-Meta-:–Alternatively,aheaderofthistypecanbeusedtodeletethecustomattributenamedintheheader.
–Thearbitraryvalueisignoredbythesystem.
ResponseStatusCodeTheresponsestatuscodeisoneofthefollowing:204(NoContent)—ThePOSToperationsucceeded4-14CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPICreatingorUpdatingAccountMetadata400(BadRequest)—ThePOSToperationisnotvalid401(Unauthorized)—Theusertokenismissingorinvalid403(Forbidden)—Theuserdoesnothavepermissiontomodifythecontainerattributes404(NotFound)—ThestorageURLreferencesanon-existentaccountorcontainer5xx—InternalServerErrorCreatingorUpdatingAccountMetadataTocreateorupdatecustomaccountattributes,usethefollowingHTTPPOSTrequest:NoteToperformthisoperation,youmustbeanaccountadministratororaCOSreselleradmin.
POST/v1/HTTP/1.
1RequiredRequestHeadersX-Auth-Token:X-Account-Meta-:–Iftheattributeexists,itsvalueisupdatedtothatspecifiedintheheader.
Else,theattributeiscreated.
ResponseStatusCodeTheresponsestatuscodeisoneofthefollowing:204(NoContent)—ThePOSToperationsucceeded400(BadRequest)—ThePOSToperationisnotvalid401(Unauthorized)—Theusertokenismissingorinvalid403(Forbidden)—Theuserdoesnothavepermissiontomodifythecontainerattributes404(NotFound)—ThestorageURLreferencesanon-existentaccount5xx—InternalServerErrorRetrievingAccountMetadataToretrieveaccountmetadatatochecktheaccountstatistics,usethefollowingHTTPHEADrequest:NoteToperformtheoperation,youmustbeanaccountadministratororaCOSreselleradmin.
HEAD/v1/HTTP/1.
14-15CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIDeletingAccountMetadataRequiredRequestHeadersX-Auth-Token:ResponseStatusCodesTheresponsestatuscodeisoneofthefollowing:2xx(Success)—TheHEADoperationsucceeded400(BadRequest)—TheHEADoperationisnotvalid401(Unauthorized)—Theusertokenismissingorinvalid403(Forbidden)—Theuserdoesnothavepermissiontomodifythecontainerattributes404(NotFound)—ThestorageURLreferencesanon-existentaccount5xx—InternalServerErrorResponseHeadersX-Account-Container-Count:–Thevalueoftheheaderisthenumberofcontainersintheaccount.
X-Account-Object-Count:–Thevalueoftheheaderisthenumberofobjectsintheaccount.
X-Account-Bytes-Used:–ThevalueoftheheaderisthetotalnumberofbytesinCOSforthespecifiedaccount.
X-Account-Meta-:–Theheaderreturnscustomaccountattributesandtheirvalues.
DeletingAccountMetadataTodeletecustomaccountattributes,usethefollowingHTTPPOSTrequest:NoteToperformtheoperation,youmustbeanaccountadministratororaCOSreselleradmin.
POST/v1/HTTP/1.
1RequiredRequestHeadersX-Auth-Token:X-Account-Meta-:–Anemptyheaderofthistypewithouttheattributevaluecanbeusedtodeletethecustomattributenamedintheheader.
X-Remove-Account-Meta-:–Alternatively,aheaderofthistypecanbeusedtodeletethecustomattributenamedintheheader.
4-16CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIAccessControlLists(ACLs)–Thearbitraryvalueisignoredbythesystem.
ResponseStatusCodeTheresponsestatuscodeisoneofthefollowing:204(NoContent)—ThePOSToperationsucceeded400(BadRequest)—ThePOSToperationisnotvalid401(Unauthorized)—Theusertokenismissingorinvalid403(Forbidden)—Theuserdoesnothavepermissiontomodifythecontainerattributes404(NotFound)—ThestorageURLreferencesanon-existentaccount5xx—InternalServerErrorAccessControlLists(ACLs)Bydefault,toaccessastorageobject,arequestermustbeanaccountadministratoroftheaccountcontainingtheobject.
Anadministratorcanmodifytheaccesspolicyforacontaineranditsstorageobjectsbyusingcontaineraccesscontrollists(ACLs).
Theadministratorcanspecifythereadandwriteaccesscontrollistsaspartofthecontainermetadata.
WhenanACLisdeleted,thedefaultaccesspolicyisrestored.
AnACLhasthefollowingform:[item[,item.
.
.
]]AnACLitemcanbeoneofthefollowing:–Alltheusersofspecifiedaccountaregrantedaccesstoobjectsinthecontainer.
:–Usersidentifiedbythecombinationofthespecifiedaccountandusernamesaregrantedaccesstoobjectsinthecontainer.
*–Anasteriskpermitsanonymousaccess.
ThisoptionisaCOSextension.
CreatingorUpdatingACLsTocreateorupdateanACL,usethefollowingHTTPPOSTrequest:NoteToperformtheoperation,youmustbeanaccountadministratororaCOSreselleradmin.
POST/v1//HTTP/1.
14-17CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIDeletingACLsRequiredRequestHeadersX-Auth-Token:X-Container-Read:–SpecifythereadACLasthevalueofthisheader.
X-Container-Write:–SpecifythewriteACLasthevalueofthisheader.
ResponseStatusCodeTheresponsestatuscodeisoneofthefollowing:204(NoContent)—ThePOSToperationsucceeded400(BadRequest)—ThePOSTrequestisnotvalid401(Unauthorized)—Theusertokenismissingorinvalid403(Forbidden)—Theuserdoesnothavepermissiontomodifythecontainerattributes404(NotFound)—ThestorageURLreferencesanon-existentaccountorcontainer5xx—InternalServerErrorDeletingACLsTodeleteanACL,usethefollowingHTTPPOSTrequest:NoteToperformtheoperation,youmustbeanaccountadministratororaCOSreselleradmin.
POST/v1//HTTP/1.
1RequiredRequestHeadersX-Auth-Token:X-Container-Read:–SpecifyanemptylistasthevalueofthisheadertodeletethereadACL.
X-Remove-Container-Read:–Alternatively,aheaderofthistypecanbeusedtodeletethereadACL.
–Thearbitraryvalueisignoredbythesystem.
X-Container-Write:–SpecifyanemptylistasthevalueofthisheadertodeletethewriteACL.
X-Remove-Container-Write:–Alternatively,aheaderofthistypecanbeusedtodeletethewriteACL.
–Thearbitraryvalueisignoredbythesystem.
4-18CiscoCloudObjectStorageRelease2.
1.
1APIGuideChapter4SwiftAPIDeletingACLsResponseStatusCodeTheresponsestatuscodeisoneofthefollowing:204(NoContent)—ThePOSToperationsucceeded400(BadRequest)—ThePOSTrequestisnotvalid401(Unauthorized)—Theusertokenismissingorinvalid403(Forbidden)—Theuserdoesnothavepermissiontomodifythecontainerattributes404(NotFound)—ThestorageURLreferencesanon-existentaccountorcontainer5xx—InternalServerError
Megalayer 商家在开始看到有提供香港服务器、香港站群服务器的时候有介绍过,后来就一直没有怎么关注。但是前几天有看到网友使用到他们家的美国独立服务器问其如何的,但是我没有使用过就不好评论,这不前几天也有介绍到Megalayer美国独立服务器。以及我们也有看到商家有提供美国站群服务器和美国大带宽服务器产品,可选30M不限制流量CN2优化线路,以及100M不限制流量国际带宽线路。新年元旦后,Me...
也有在上个月介绍到糖果主机商12周年的促销活动,我有看到不少的朋友还是选择他们家的香港虚拟主机和美国虚拟主机比较多,同时有一个网友有联系到推荐入门的个人网站主机,最后建议他选择糖果主机的迷你主机方案,适合单个站点的。这次商家又推出所谓的秋季活动促销,这里一并整理看看这个服务商在秋季活动中有哪些值得选择的主机方案,比如虚拟主机最低可以享受六折,云服务器可以享受五折优惠。 官网地址:糖果主机秋季活动促...
pacificrack又追加了3款特价便宜vps搞促销,而且是直接7折优惠(一次性),低至年付7.2美元。这是本月第3波便宜vps了。熟悉pacificrack的知道机房是QN的洛杉矶,接入1Gbps带宽,KVM虚拟,纯SSD RAID10,自带一个IPv4。官方网站:https://pacificrack.com支持PayPal、支付宝等方式付款7折秒杀优惠码:R3UWUYF01T内存CPUSS...
internalservererror为你推荐
操作http副刊2016年8月30日操作httpmediawikiwiki,wikipedia与mediawiki三者的区别my.qq.commy.qq.com我是CF会员吗特朗普吐槽iPhone为什么这么多人讨厌苹果呢?iPhone配置不足但是iOS流畅度确实很高很强大,性能领先几乎所有国产flashfxp下载求最新无需注册的FlashFXP下载地址生药http结点cuteftp三友网广州三友集团在韶关分公司么?
域名反查 万网域名代理 godaddy域名解析教程 2014年感恩节 l5520 php探针 圣诞节促销 panel1 java虚拟主机 本网站在美国维护 699美元 域名评估 泉州电信 阿里校园 路由跟踪 下载速度测试 湖南idc ledlamp 登陆qq空间 阿里云邮箱怎么注册 更多