Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 12593 invoked from network); 3 Nov 2009 20:37:34 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 3 Nov 2009 20:37:34 -0000 Received: (qmail 97202 invoked by uid 500); 3 Nov 2009 20:37:33 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 97120 invoked by uid 500); 3 Nov 2009 20:37:33 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 97110 invoked by uid 99); 3 Nov 2009 20:37:33 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Nov 2009 20:37:33 +0000 X-ASF-Spam-Status: No, hits=0.4 required=5.0 tests=AWL,BAYES_00,MSGID_MULTIPLE_AT,NORMAL_HTTP_TO_IP,RCVD_IN_SORBS_WEB,WEIRD_PORT X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [89.36.166.90] (HELO mail.ro1-jdhosting.net) (89.36.166.90) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Nov 2009 20:37:30 +0000 Received: from LygosPC ([92.82.77.22]) by ro1-jdhosting.net with MailEnable ESMTP; Tue, 3 Nov 2009 22:36:29 +0200 From: "Sebastian Negomireanu" To: References: <4AEFFEC9.2020404@rogerbinns.com> <-818254707187926005@unknownmsgid> <46aeb24f0911030422n334467f5x71a0b312105d3b7f@mail.gmail.com> <-2475371172427800684@unknownmsgid> <46aeb24f0911030615p7a846f3bnd5e9eecea24629e9@mail.gmail.com> In-Reply-To: <46aeb24f0911030615p7a846f3bnd5e9eecea24629e9@mail.gmail.com> Subject: RE: Performance issue Date: Tue, 3 Nov 2009 22:37:43 +0200 Message-ID: <001e01ca5cc5$7efbe2f0$7cf3a8d0$@negomireanu@justdesign.ro> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_NextPart_000_001F_01CA5CD6.4284B2F0" X-Mailer: Microsoft Office Outlook 12.0 Content-Language: en-us Thread-Index: AcpckAkHTWjHqZgmTiGw3/PdJm3DyAANJ6Eg X-ME-Bayesian: 0.000000 ------=_NextPart_000_001F_01CA5CD6.4284B2F0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable After monitoring with Wireshark, it seems that there aren't any other operations happening at the same time. I've attached the whole HTTP conversation. As you can see from the http dump, I check if the test database exists, = drop it, recreate it, add two views to it and then add a document. This whole process takes 7 seconds to complete. Best regards, Sebastian Negomireanu | CTO / Managing Partner JustDesign Sibiu, Romania +40-726-181186 | +40-788-757462 sebastian.negomireanu@justdesign.ro SC JustDesign SRL | Str. Dorului 20, 550352, Sibiu, Romania +40-269-210008 | office@justdesign.ro | www.justdesign.ro=20 -----Original Message----- From: Robert Newson [mailto:robert.newson@gmail.com]=20 Sent: Tuesday, November 03, 2009 4:15 PM To: user@couchdb.apache.org Subject: Re: Performance issue One thing that snagged me one time was a client that sent "Expect: Continue" header. There was a time when couchdb didn't recognize this case-insensitively. For me, this caused a two second delay to all requests. B. On Tue, Nov 3, 2009 at 1:34 PM, Sebastian Negomireanu wrote: > I am connecting to the database from my .NET application (which uses = Divan > as a library). But I've put it through a profiler and I get the large delay > when waiting for the response from the database. The time needed to = run the > application itself (prepare the JSON message, parse the response etc.) = is > minimal compared to the time it waits for the request. Actually = sending the > request takes less than 5ms. > > Anyway, I'll monitor everything with wireshark a bit later today and = come > back with the results. Maybe, as Roger pointed out, my infrastructure = is the > cause for this. > > > Best regards, > Sebastian Negomireanu | CTO / Managing Partner JustDesign Sibiu, = Romania > +40-726-181186 | +40-788-757462 > sebastian.negomireanu@justdesign.ro > > SC JustDesign SRL | Str. Dorului 20, 550352, Sibiu, Romania > +40-269-210008 | office@justdesign.ro | www.justdesign.ro > > > -----Original Message----- > From: Robert Newson [mailto:robert.newson@gmail.com] > Sent: Tuesday, November 03, 2009 2:22 PM > To: user@couchdb.apache.org > Subject: Re: Performance issue > > What HTTP client are you using? > > On Tue, Nov 3, 2009 at 11:06 AM, Sebastian Negomireanu > wrote: >> Ok I will try that and come back with results. >> >> >> Best regards, >> Sebastian Negomireanu | CTO / Managing Partner JustDesign Sibiu, = Romania >> +40-726-181186 | +40-788-757462 >> sebastian.negomireanu@justdesign.ro >> >> SC JustDesign SRL | Str. Dorului 20, 550352, Sibiu, Romania >> +40-269-210008 | office@justdesign.ro | www.justdesign.ro >> >> -----Original Message----- >> From: Roger Binns [mailto:rogerb@rogerbinns.com] >> Sent: Tuesday, November 03, 2009 11:59 AM >> To: user@couchdb.apache.org >> Subject: Re: Performance issue >> >> -----BEGIN PGP SIGNED MESSAGE----- >> Hash: SHA1 >> >> Sebastian Negomireanu wrote: >>> In both scenarios, I get response times around 500ms >> >> In these kind of situations I am a big fan of using Wireshark to see > exactly >> what the response time is. =A0There could be all sorts of funky stuff = going > on >> such as proxy servers, DNS lookups, IPv6 failing and then going to = IPv4 > and >> who knows what else that may be major contributions to the time as > observed >> by the client side code. >> >> Roger >> -----BEGIN PGP SIGNATURE----- >> Version: GnuPG v1.4.9 (GNU/Linux) >> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org >> >> iEYEARECAAYFAkrv/sgACgkQmOOfHg372QTcGQCdF0U0esBf+ODH54UESA1onxr2 >> i8AAn3beEdWJr0GbJXP1Z0hFirMWqyPO >> =3DmUU0 >> -----END PGP SIGNATURE----- >> >> >> > > > ------=_NextPart_000_001F_01CA5CD6.4284B2F0 Content-Type: text/plain; name="http stream.txt" Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename="http stream.txt" HEAD /squarecms-test-v5_0_0 HTTP/1.1 Host: 192.168.0.156:5984 HTTP/1.1 200 OK Server: CouchDB/0.10.0 (Erlang OTP/R13B) Date: Tue, 03 Nov 2009 20:21:39 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 203 Cache-Control: must-revalidate HEAD /squarecms-test-v5_0_0 HTTP/1.1 Host: 192.168.0.156:5984 HTTP/1.1 200 OK Server: CouchDB/0.10.0 (Erlang OTP/R13B) Date: Tue, 03 Nov 2009 20:21:40 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 203 Cache-Control: must-revalidate DELETE /squarecms-test-v5_0_0 HTTP/1.1 Host: 192.168.0.156:5984 HTTP/1.1 200 OK Server: CouchDB/0.10.0 (Erlang OTP/R13B) Date: Tue, 03 Nov 2009 20:21:40 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 12 Cache-Control: must-revalidate {"ok":true}=0A= HEAD /squarecms-test-v5_0_0 HTTP/1.1 Host: 192.168.0.156:5984 HTTP/1.1 404 Object Not Found Server: CouchDB/0.10.0 (Erlang OTP/R13B) Date: Tue, 03 Nov 2009 20:21:41 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 44 Cache-Control: must-revalidate PUT /squarecms-test-v5_0_0 HTTP/1.1 Host: 192.168.0.156:5984 HTTP/1.1 201 Created Server: CouchDB/0.10.0 (Erlang OTP/R13B) Location: http://192.168.0.156:5984/squarecms-test-v5_0_0 Date: Tue, 03 Nov 2009 20:21:41 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 12 Cache-Control: must-revalidate {"ok":true}=0A= HEAD /squarecms-test-v5_0_0 HTTP/1.1 Host: 192.168.0.156:5984 HTTP/1.1 200 OK Server: CouchDB/0.10.0 (Erlang OTP/R13B) Date: Tue, 03 Nov 2009 20:21:42 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 201 Cache-Control: must-revalidate GET = /squarecms-test-v5_0_0/SquareCMS.Server.VirtualFileSystem,%20Version=3D1.= 0.0.0,%20Culture=3Dneutral,%20PublicKeyToken=3Dnull HTTP/1.1 Host: 192.168.0.156:5984 HTTP/1.1 404 Object Not Found Server: CouchDB/0.10.0 (Erlang OTP/R13B) Date: Tue, 03 Nov 2009 20:21:42 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 41 Cache-Control: must-revalidate {"error":"not_found","reason":"missing"}=0A= POST /squarecms-test-v5_0_0/ HTTP/1.1 Host: 192.168.0.156:5984 Content-Length: 372 Expect: 100-continue HTTP/1.1 100 Continue {"_id":"_design/files","language":"javascript","views":{"mapPathToId":{"m= ap":"function(doc) {\r\n var path =3D doc.path;\r\n if (typeof = (path) =3D=3D 'undefined' || doc.isFolder || doc.type !=3D = 'SquareCMS.Server.VirtualFileSystem.VirtualFile') {\r\n = return;\r\n }\r\n \r\n path.push(doc.name);\r\n path =3D = path.join('/');\r\n emit(path, null);\r\n}"}}}HTTP/1.1 201 Created Server: CouchDB/0.10.0 (Erlang OTP/R13B) Location: http://192.168.0.156:5984/squarecms-test-v5_0_0/_design/files Date: Tue, 03 Nov 2009 20:21:43 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 76 Cache-Control: must-revalidate {"ok":true,"id":"_design/files","rev":"1-2836f15cb6a43f2c1d990e2ff84b803d= "}=0A= POST /squarecms-test-v5_0_0/ HTTP/1.1 Host: 192.168.0.156:5984 Content-Length: 181 Expect: 100-continue HTTP/1.1 100 Continue {"_id":"_design/types","language":"javascript","views":{"getDocumentsByTy= pe":{"map":"function(doc) {\r\n = emit(doc.type,doc)\r\n }"}}}HTTP/1.1 201 Created Server: CouchDB/0.10.0 (Erlang OTP/R13B) Location: http://192.168.0.156:5984/squarecms-test-v5_0_0/_design/types Date: Tue, 03 Nov 2009 20:21:44 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 76 Cache-Control: must-revalidate {"ok":true,"id":"_design/types","rev":"1-f397446b1a72dd3ffd6929ed46fd71da= "}=0A= POST /squarecms-test-v5_0_0/ HTTP/1.1 Host: 192.168.0.156:5984 Content-Length: 191 Expect: 100-continue HTTP/1.1 100 Continue {"_id":"SquareCMS.Server.VirtualFileSystem, Version=3D1.0.0.0, = Culture=3Dneutral, = PublicKeyToken=3Dnull","type":"SquareCMS.Server.Infrastructure.Data.Datab= aseVersion","major":0,"minor":0,"build":1}HTTP/1.1 201 Created Server: CouchDB/0.10.0 (Erlang OTP/R13B) Location: = http://192.168.0.156:5984/squarecms-test-v5_0_0/SquareCMS.Server.VirtualF= ileSystem, Version=3D1.0.0.0, Culture=3Dneutral, PublicKeyToken=3Dnull Date: Tue, 03 Nov 2009 20:21:44 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 152 Cache-Control: must-revalidate {"ok":true,"id":"SquareCMS.Server.VirtualFileSystem, Version=3D1.0.0.0, = Culture=3Dneutral, = PublicKeyToken=3Dnull","rev":"1-ad7172662c180be33d1fdebca7a61c35"}=0A= GET = /squarecms-test-v5_0_0/_design/types/_view/getDocumentsByType?startkey=3D= %22SquareCMS.Server.VirtualFileSystem.VirtualFile%22&endkey=3D%22SquareCM= S.Server.VirtualFileSystem.VirtualFile%22&include_docs=3Dtrue HTTP/1.1 Host: 192.168.0.156:5984 HTTP/1.1 200 OK Server: CouchDB/0.10.0 (Erlang OTP/R13B) Date: Tue, 03 Nov 2009 20:21:45 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 38 Cache-Control: must-revalidate {"total_rows":1,"offset":1,"rows":[]}=0A= POST /squarecms-test-v5_0_0/_bulk_docs HTTP/1.1 Content-Type: application/json Host: 192.168.0.156:5984 Content-Length: 11 Expect: 100-continue HTTP/1.1 100 Continue {"docs":[]}HTTP/1.1 201 Created Server: CouchDB/0.10.0 (Erlang OTP/R13B) Date: Tue, 03 Nov 2009 20:21:45 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 3 Cache-Control: must-revalidate []=0A= POST /squarecms-test-v5_0_0/ HTTP/1.1 Host: 192.168.0.156:5984 Content-Length: 255 Expect: 100-continue HTTP/1.1 100 Continue {"type":"SquareCMS.Server.VirtualFileSystem.VirtualFile","name":"file.txt= ","path":["Files","Category"],"creationDate":"\/Date(1257279744207+0200)\= /","createdBy":null,"lastModifiedDate":"\/Date(1257279744207+0200)\/","la= stModifiedBy":null,"isFolder":false}HTTP/1.1 201 Created Server: CouchDB/0.10.0 (Erlang OTP/R13B) Location: = http://192.168.0.156:5984/squarecms-test-v5_0_0/f27d50b5254968c88ca884aaa= 7ebab1d Date: Tue, 03 Nov 2009 20:21:46 GMT Content-Type: text/plain;charset=3Dutf-8 Content-Length: 95 Cache-Control: must-revalidate {"ok":true,"id":"f27d50b5254968c88ca884aaa7ebab1d","rev":"1-3f91624434d2a= 9707bb86f861473b111"}=0A= GET = /squarecms-test-v5_0_0/_design/types/_view/getDocumentsByType?startkey=3D= %22SquareCMS.Server.VirtualFileSystem.VirtualFile%22&endkey=3D%22SquareCM= S.Server.VirtualFileSystem.VirtualFile%22&include_docs=3Dtrue HTTP/1.1 Host: 192.168.0.156:5984 HTTP/1.1 200 OK Transfer-Encoding: chunked Server: CouchDB/0.10.0 (Erlang OTP/R13B) Etag: "85EQOERL1PXJ5A14AK07P31O9" Date: Tue, 03 Nov 2009 20:21:46 GMT Content-Type: text/plain;charset=3Dutf-8 Cache-Control: must-revalidate 335 {"total_rows":2,"offset":1,"rows":[ {"id":"f27d50b5254968c88ca884aaa7ebab1d","key":"SquareCMS.Server.VirtualF= ileSystem.VirtualFile","value":{"_id":"f27d50b5254968c88ca884aaa7ebab1d",= "_rev":"1-3f91624434d2a9707bb86f861473b111","type":"SquareCMS.Server.Virt= ualFileSystem.VirtualFile","name":"file.txt","path":["Files","Category"],= "creationDate":"/Date(1257279744207+0200)/","createdBy":null,"lastModifie= dDate":"/Date(1257279744207+0200)/","lastModifiedBy":null,"isFolder":fals= e},"doc":{"_id":"f27d50b5254968c88ca884aaa7ebab1d","_rev":"1-3f91624434d2= a9707bb86f861473b111","type":"SquareCMS.Server.VirtualFileSystem.VirtualF= ile","name":"file.txt","path":["Files","Category"],"creationDate":"/Date(= 1257279744207+0200)/","createdBy":null,"lastModifiedDate":"/Date(12572797= 44207+0200)/","lastModifiedBy":null,"isFolder":false}} 4 ]} 1 =0A= 0 ------=_NextPart_000_001F_01CA5CD6.4284B2F0--