slashhttp500

http500  时间:2021-04-13  阅读:()
APPENDIXA251CouchDBAPIReferenceThisappendixisanoverviewoftheAPIcallsyoucanmaketotheCouchDBserver.
ServerAPIsServerInformationRequestMethod:GETRequestURI:/RequestHeaders:NoneRequestBody:EmptyRequestParameters:NoneDescription:ReturnsawelcomemessageandtheCouchDBversionnumberSampleRequestURI:http://127.
0.
0.
1:5984/Thefollowingisasampleresponse:{"couchdb":"Welcome","version":"0.
9.
1"}APPENDIXACOUCHDBAPIREFERENCE252CurrentConfigurationRequestMethod:GETRequestURI:/_configRequestHeaders:NoneRequestBody:EmptyRequestParameters:NoneDescription:ReturnsallofCouchDB'sconfigurationoptionsandtheircurrentvaluesSampleRequestURI:http://127.
0.
0.
1:5984/_configThefollowingisasampleresponse:{"httpd_design_handlers":{"_list":"{couch_httpd_show,handle_view_list_req}","_show":"{couch_httpd_show,handle_doc_show_req}","_view":"{couch_httpd_view,handle_view_req}"},"httpd_global_handlers"couch_httpd_misc_handlers,handle_welcome_req,GET/HTTP/1.
1>User-Agent:curl/7.
16.
3(powerpc-apple-darwin9.
0)libcurl/7.
16.
3OpenSSL/0.
9.
7lzlib/1.
2.
3>Host:127.
0.
0.
1:5984>Accept:*/*>1200OK9.
0(ErlangOTP/R13B)9.
0"}*Connection#0tohost127.
0.
0.
1leftintact*Closingconnection#0Bydefault,ifarequestmethodisnotsupplied,curlwillperformaGETrequest.
TomakeanHTTPrequestwithadifferentmethod,suchasPUT,youcanusethe-Xargument.
ThefollowingcommandmakesaPUTrequesttotheURI/mydb,whichwillcreateanewdatabasenamedmydb:curl-XPUThttp://127.
0.
0.
1:5984/mydbIfyouneedtospecifyheadersinyourHTTPrequest,youusethe-Hargument.
ThefollowingexampleusestheDestinationheadertodefinewhereadocumentshouldbecopiedto:curl-XCOPYhttp://127.
0.
0.
1:5984/mydb/doc1-H'Destination:doc2'ManyofCouchDB'sAPImethodsrequireyoutoincludedatainthemessagebody.
Youcansupplythisdatausingthe-dargument,asshowninthefollowingreplicationexample:curl-XPOSThttp://127.
0.
0.
1:5984/_replicate-d'{"source":"db_one","target":"db_two"}'Thepreviousexampleworksquitenicely,becausethedatabeingsuppliedintherequestbodyisshort.
Butwhatifyouneedtosupplyalargesetofdata,suchasanumberofdocumentsbeingaddedusingthebulkdocumentAPIInthiscase,youcansavethedatainafile,forexampledocuments.
json,andthentellcurltoloadthedatafromthisfile.
Thefollowingisanexampleofthistypeofrequest:curl-XPOSThttp://127.
0.
0.
1:5984/mydb/_bulk_docs-d@documents.
jsonAPPENDIXBHTTPANDCURLREFERENCE287curlhasahostofothercommand-linearguments,fartoomanytolisthere.
Afinalargumentthatyoumayfinduseful,however,isthe-oflag.
Youcanusethistooutputtheresponsetoafile,asfollows:curlhttp://127.
0.
0.
1:5984/mydb/mydoc-omydoc.
jsonThiswillstorethedocumentwithdocumentIDmydocinthefilemydoc.
json.
289IndexSymbols+(plus)icon(Futon),63/(slash)asrequestURI,251AACIDproperties,6adhocviews.
SeetemporaryviewsADC(Apple'sDeveloperConnection),32administrationtool.
SeeFutonadministrationtoolaggregatingresultsonviews,143–50_all_dbsresource,104,258_all_docsresource,57,229,267,268_all_docs_by_seqresource,58,269,270all-or-nothingbulkupdates,235Apple'sDeveloperConnection(ADC),32applicationdevelopment,185–209withCouchApp.
SeeCouchAppwithCouchdbkitlibrary(Python),185–91withCouchRestlibrary,191–200withDjangoextensions(Python),200–209apt-getpackagemanager,12arrays,JSON,89,90loopingthrough,96–102atomicity,6attachmentsdeleting,273uploadingwithFuton,76–78,272_attachmentssubdirectory(couchappsdirectory),172Bbackups,248bind_addressoption,81bookmarksapplication(example),200–209booleandatatype(JSON),89buildingCouchDBfromsourcecode,19–28Erlang,23ICU,25Libcurllibrary,24Spidermonkey,25Subversion,26_bulk_docsresource,232,275bulkfetchingofdocuments,229–32,275bulkwritingofdocuments,232–35Cclustering,250CompactDatabaselink(Futon),78–80_compactresource,261compactingdatabases,78–80,224–28,261complexkeys,157_configresource,252configurationinformation,retrieving,252configuringCouchDBinstallation,80,243–46conflictresolution,246–47_conflictsdocument,246consistency,6Content-Typeheader,272,277COPYrequests(HTTP),50,266,284copyingdocuments,266CouchApp,163–84buildingtaskmanager,169–84gettingstarted,165–69installing,163–65couchappsdirectory,creating,165CouchDB,about,3–5CouchDBadministrationtool.
SeeFutonadministrationtoolCouchDBAPI,7triggeringdatabasereplication,223viewsand,119–23map/reducewith,135–36CouchDBapplications,developing,185–209withCouchApp.
SeeCouchAppwithCouchdbkitlibrary(Python),185–91withCouchRestlibrary,191–200withDjangoextensions(Python),200–209CouchDBconfigurationoptions,80CouchDBConfigurationtool(Futon),80CouchDBdependencypackages,12Erlang,23INDEX290ICU,25libcurl,24Spidermoney,25Subversion,26updating(MacOSX),44CouchDBdeployment,241–50backup,248clustering,250configuration,243–46conflictresolution,246–47faulttoleranceandloadbalancing,249measuringperformance,241–43security,247–48CouchDBdocuments,about,6.
Seealsodocumentscouchdbfolder,27CouchDBinstallationonLinux,9–28buildingfromsourcecode,19–28Erlang,23ICU,25Libcurllibrary,24Spidermonkey,25Subversion,26configurationoptions,243–46FedoraLinux,14–19UbuntuLinux8.
10,12–15CouchDBinstallationonMacOSX,29–46configurationoptions,243–46MacPortspackagemanager,34–40usingCouchDBX,45–46Xcodedevelopertools,29–34couchdb-loungeframework,250couchdbservice,configuring,13couchdbuser,creating,13,27CouchDBviews.
SeeviewsCouchdbkitlibrary,185–91Djangoextensions,200–209installing,186CouchDBXpackage,45–46CouchRestlibrary,191–200CouchTasksapplication(example),169–84COUNTfunction(SQL),138countingwordswithmap/reduce(example),139–41CreateDatabaselink(Futon),63,65–70CreateDocumentlink(Futon),70–76curlutility,13,19,50accessingviews,120,135determiningdatabasesize,227enteringJSONdatathrough,56howtouse,51performingHTTPrequests,285–88D-doption,curlutility,51,54datarelationships,viewsand,154–58datatypesJSON,50,89limitingmapfunctionswith,126databasesaddingdocumentsto,54–57,262,263inbulk,232–35usingCouchdbkit(forPython),187usingCouchRest(forRuby),194allowingremoteconnectionsto,81APIsfor(list),256–61backups,248compacting,78–80,224–28,261conflictresolution,246–47creating,49,51–57,256withFuton,65–70inPython,186inRuby,193deleting,53,257deletingdocumentsfrom,55fetchingdocumentsinbulk,229–32,275listing,258replicating,83–85,211–24,260forbackup,248incrementalreplication,215triggeringreplicationfromapplications,223retrievinginformationon,259security,247–48sizeof,determining,227updatingdocumentsin,57,264inbulk,232–35views.
SeeviewsDELETErequests(HTTP),50,265,273,284_deletedmetafield(documents),234deletingattachments,273databases,53,257documents,55,265olddocumentrevisions.
Seecompactiondependencypackages,installing,12Erlang,23ICU,25libcurl,24Spidermonkey,25Subversion,26updating(MacOSX),44deployingCouchDB,241–50backup,248clustering,250configuration,243–46conflictresolution,246–47INDEX291faulttoleranceandloadbalancing,249measuringperformance,241–43security,247–48descendingargument(views),58,152designdocuments,116–18creating,276asJSONobjects,103languageandviewsfields,117permanentviewsin,121showfunctionsin,235–38,280_designresource,276,278,279,280,281,282Destinationheader,266developingCouchDBapplications,185–209withCouchApp.
SeeCouchAppwithCouchdbkitlibrary(Python),185–91withCouchRestlibrary,191–200withDjangoextensions(Python),200–209disk_sizevalue,227Djangoextensions,200–209documentrevisions,6deletingdocumentsand,55purgingold(compaction),224–28_revfield,103document-orienteddatabases,5documentsaddingtodatabases,54–57,262,263inbulk,232–35usingCouchdbkit(forPython),187usingCouchRest(forRuby),194APIsfor,listof,262–75attachingfilesto,76–78,272backupsof,248copying,266creatingwithFuton,70–76deleting,55,265designdocuments.
Seedesigndocumentsfetchinginbulk,229–32,275_idand_revfields,103bulkfetchingand,231bulkwritingand,234JSON,presentinginnon-JSONformats,235–38listing,267,268,269,270querying(returning).
Seeviewsupdating,57,264inbulk,232–35viewing,271.
Seealsoviewsducktyping,112durability,6Eeasy_installutility,165,185emitfunction,126endkeyargument(views),153Erlang,building,23executingviews.
SeeviewsFFabricformulalanguage,4faulttolerance,249FedoraLinux,installingCouchDBon,14–19fetchingdocumentsinbulk,229–32,275file_existserror,52files,attachingtodocuments,76–78,272filteringresults(views),151–54Futonadministrationtool,8,63–86compactingdatabases,78–80,224–28creatingdatabases,65–70creatingdocuments,70–76creatingviews,109–13.
Seealsoviewspermanentviews,113–16map/reducein,127–35replication.
Seereplicatingdatabasesshowfunctions,creating,235TestSuite,running,14,20,29,46databasescreatedby,53toolsof,80–85uploadingattachments,76–78GGETrequests(HTTP),50,284Google'smap/reducefunctionality,125groupingresultsonviews,143–50H-Hoption,curlutility,51historyofCouchDB,4HTTPrequests,283performingwithcurl,285–88HTTPresponses,50,284statuscodesfor,285IICU,building,25_idfield(documents),103fordesigndocuments,103fetchingdocumentsinbulk,231writingdocumentsinbulk,234incrementalreplication,215index.
htmlfile(couchappsdirectory),167installingCouchDBonLinux,9–28buildingfromsourcecode,19–28Erlang,23ICU,25Libcurllibrary,24INDEX292Spidermonkey,25Subversion,26configurationoptions,243–46FedoraLinux,14–19UbuntuLinux8.
10,12–15installingCouchDBonMacOSX,29–46configurationoptions,243–46MacPortspackagemanager,34–40usingCouchDBX,45–46Xcodedevelopertools,29–34isolation,6JJavaScriptObjectNotation.
SeeJSON,SeeJSONJavascriptviewengine,7,57JSON(JavaScriptObjectNotation),7,50,87–105about,87advantages,87CouchDBwith,103–4encapsulatingwithsinglequotes,54enteringdatathroughcurl,56loopingthrougharrays,96–102presentingdocumentsasnon-JSON,235–38roleinasynchronouswebapplications,98structures,defining,91–96syntaxanddatatypes,88–91KKatz,Damien,4keyargument(views),153Llanguagefield(designdocuments),103,117launchingCouchDBserver,13,18,28Libcurllibrary,building,24limitargument(views),154limitqueryparameter,58Linux,installingCouchDBon,9–28buildingfromsourcecode,19–28Erlang,23ICU,25Libcurllibrary,24Spidermonkey,25Subversion,26configurationoptions,243–46FedoraLinux,14–19UbuntuLinux8.
10,12–15listfunctions,238,281,282_listresource,281,282listingdatabases,258listingdocuments,267,268,269,270listskeys,235loadbalancing,249"Localdatabase"option(replication),83,213loopingthroughJSONarrays,96–102MMacOSX,installingCouchDBon,29–46configurationoptions,243–46MacPortspackagemanager,34–40usingCouchDBX,45–46Xcodedevelopertools,29–34MacPortspackagemanager,installing,34–40mainarea,Futon,63main.
cssfile(styledirectory),170,180mapfunction,110,125,Seealsoviews,Seealsomap/reduceconcept;viewsinCouchAppviews,178CouchDBAPIand,135–36creating,126creatinginFuton,127–35SQLqueriesvs.
,136–38wordcountexample,139–41map/reduceconcept.
SeealsomapfunctioninCouchDB,126–27CouchDBAPIand,135–36defined,125inFuton,127–35reduce.
SeereducefunctionSQLqueriesvs.
,136–38wordcountexample,139–41MapFunctionbox(Futon),130map.
jsfile,178Math.
roundfunction(JavaScript),146maxfunction,147measuringCouchDBperformance,241–43minfunction,147Nnavigationbar,Futon,63nonatomicbulkupdates,234nulldatatype(JSON),89nullvalues,108numberdatatype(JSON),89Oobjects,JSON,50,88,89creating(defining),92orderingresults(views),151–54Overviewheading(Futon),63INDEX293Ppaginationbar(Futon),63passwordforuseraccount,13performanceclustering,250loadbalancing,249measurementof,241–43runtimestatistics,retrieving,253permanentviews,109,113–16indesigndocuments,121executingwithCouchDBAPI,120map/reducewith,135–36map/reduce.
Seemap/reduceconceptquerying,278,279pingcommand,217plus(+)icon(Futon),63POSTrequests(HTTP),50,284fetchingdocumentsinbulk,229–32,275writingdocumentsinbulk,232–35purgingolddocumentrevisions.
SeecompactionpushingCouchAppstoCouchDB,165,168PUTrequests(HTTP),50,284pycurlutility,installing,186Pythonexecutingviewsfrom,190installing,163,185PythonapplicationsCouchdbkitlibrarywith(Python),185–91Djangoframework,185–91Qqueryingdatabase.
Seeviewsqueryingrelateddata,155RRails,installing,191RDBMS(relationaldatabasemanagementsystems),107reducefunction,125,SeealsomapfunctioninCouchAppviews,178CouchDBAPIand,135–36creating,126creatinginFuton,127–35SQLqueriesvs.
,136–38wordcountexample,139–41ReduceFunctionbox(Futon),132reduce.
jsfile,178relateddata,viewsand,154–58relationaldatabasemanagementsystems,107remoteconnectionstodatabases,81"Remotedatabase"option(replication),213_replicateresource,260replicatingdatabases,83–85,211–24,260forbackup,248incrementalreplication,215triggeringreplicationfromapplications,223replicationtestfailure,15Replicatortool(Futon),83–85,211–24incrementalreplication,216requests.
SeeHTTPrequestsrereduceargument(reducefunction),127,148responses.
SeeHTTPresponsesRESTful,CouchDBAPIas,7returningdocumentswithqueries.
Seeviews_revmetafield(documents),103fordesigndocuments,103fetchingdocumentsinbulk,231writingdocumentsinbulk,234reversingresultsorderonviews,152revisions,document,6deletingdocumentsand,55purgingold(compaction),224–28_revfield,103roundfunction(JavaScript),146Rubydevelopingapplicationsin,191–200executingviewsfrom,198installingRubyGems,191runtimestatistics,retrieving,253Ssavingviewsaspermanent,113–16schema-freeDBMS,CouchDBas,5,49security,247–48SELECTstatements(SQL)vs.
map/reduce,136–38serverAPIs,listof,251–55serverclustering,250serverinformation,retrieving,251setuptools(Python),164,185showfunctions,235–38,280_showresource,280showskeys,235sizeofdatabase,determining,227/(slash)asrequestURI,251sourcecode,buildingCouchDBfrom,19–28Erlang,23ICU,25Libcurllibrary,24Spidermonkey,25Subversion,26Spidermonkey,building,25Spidermonkey-basedengine.
SeeJavaScriptviewengineINDEX294SQL(StructuredQueryLanguage),107SQLqueriesvs.
map/reduce,136–38stand-aloneapplications,building,185–209withCouchApp.
SeeCouchAppwithCouchdbkitlibrary(Python),185–91withCouchRestlibrary,191–200withDjangoextensions(Python),200–209startingCouchDBserver,13,18,28startkeyargument(views),153_statsresource,253statuscodesforHTTPresponses,285Statuspage(Futon),82storingrelateddata,155stringdatatype(JSON),89StructuredQueryLanguage.
SeeSQLstructures,JSON,91–96stylesubdirectory(couchappsdirectory),167Subversion,building,26sudocommand,MaxOSXLeopardand,43Ttaskmanagerapplication,building,169–84_temp_viewresource,277temporaryviews,109creating,109–13executingwithCouchDBAPI,119makingpermanent,113–16map/reduce.
Seemap/reduceconceptquerying,277Terminalapplication(MacOS),39Terminalwindow,opening,12,16testdatabases,53TestSuite,running,14,20,29,46databasescreatedby,53total_rowsfield,58triggeringdatabasereplication,223types.
SeedatatypesUUbuntuLinux8.
10,installingCouchDBon,12–15update_notificationsection(local.
ini),249updatingdocuments,57,264inbulk,232–35UploadAttachmentlink(Futon),76–78useraccount,creating,13,27UUIDs,retrieving,255_uuidsresource,255Vversioncontrol,compactionand,228viewAPIs,listof,276–82viewengines,108,SeealsoJavaScriptviewenginemap/reduce.
Seemap/reduceconcept_viewresource,278,279viewingdocuments,271views,7,57–59,107–23,143–59,267advancedaggregation,143–50inCouchApps,178CouchDBAPIand,119–23,135–36creating,109–13fromPython(withCouchdbkit),190fromRuby(withCouchRest),198designdocumentswith,116–18map/reduce.
Seemap/reduceconceptorderingandfilteringresults,151–54permanentviews,109,113–16indesigndocuments,121executingwithCouchDBAPI,120querying,277workingwithrelateddata,154–58viewsfield(designdocuments),103,117viewssubdirectory(couchappsdirectory),178Wwgetutility,201wordcountwithmap/reduce(example),139–41writingdocuments.
Seedocuments,addingtodatabasesX-Xoption,curlutility,51Xcodedevelopertools,installing,29–34X-Couch-Full-Commitheader,264,275Yyum,installingCouchDBusing,14–1

PacificRack 端午节再来一款年付$38 VPS主机 2核4GB内存1TB流量

这不端午节和大家一样回家休息几天,也没有照顾网站的更新。今天又出去忙一天没有时间更新,这里简单搜集看看是不是有一些商家促销活动,因为我看到电商平台各种推送活动今天又开始一波,所以说现在的各种促销让人真的很累。比如在前面我们也有看到PacificRack 商家发布过年中活动,这不在端午节(昨天)又发布一款闪购活动,有些朋友姑且较多是端午节活动,刚才有看到活动还在的,如果有需要的朋友可以看看。第一、端...

哪里购买香港云服务器便宜?易探云2核2G低至18元/月起;BGP线路年付低至6.8折

哪里购买香港云服务器便宜?众所周知,国内购买云服务器大多数用户会选择阿里云或腾讯云,但是阿里云香港云服务器不仅平时没有优惠,就连双十一、618、开年采购节这些活动也很少给出优惠。那么,腾讯云虽然海外云有优惠活动,但仅限新用户,购买过腾讯云服务器的用户就不会有优惠了。那么,我们如果想买香港云服务器,怎么样购买香港云服务器便宜和优惠呢?下面,云服务器网(yuntue.com)小编就介绍一下!我们都知道...

Buyvm:VPS/块存储补货1Gbps不限流量/$2起/月

BuyVM测评,BuyVM怎么样?BuyVM好不好?BuyVM,2010年成立的国外老牌稳定商家,Frantech Solutions旗下,主要提供基于KVM的VPS服务器,数据中心有拉斯维加斯、纽约、卢森堡,付费可选强大的DDOS防护(月付3美金),特色是1Gbps不限流量,稳定商家,而且卢森堡不限版权。1G或以上内存可以安装Windows 2012 64bit,无需任何费用,所有型号包括免费的...

http500为你推荐
支持ipad企业推广企业营销活动主要包括哪些内容?access数据库修复编程怎样实现access中对数据库的修复功能。新iphone也将禁售苹果ID换了个新的怎么还是停用美要求解锁iPhoneiPhone连接Mac的时候出现提示需要解锁iPhone360公司迁至天津请问360公司的全称是什么?泉州商标注册请问泉州商标注册要怎么办理?在哪办理?12306.com注册12306邮箱地址怎么写网站方案设计网站文案策划怎么写站点管理工行网点现场管理人员主要职责是什么
花生壳域名 域名服务器的作用 密码泄露 evssl证书 panel1 网站木马检测工具 优酷黄金会员账号共享 石家庄服务器托管 华为云建站 云服务是什么意思 深圳主机托管 tracker服务器 香港博客 建站行业 超低价 blaze 大硬盘分区 瓦工工具 广州服务器数据恢复 web服务器安全配置 更多