Re: clucene and couchdb

2010-06-06 Thread Robert Newson
...@vertigrated.com wrote: On Fri, Jun 4, 2010 at 5:49 PM, Robert Newson robert.new...@gmail.comwrote: Everything I have testwise is at http://github.com/rnewson/couchdb-lucene I understand the reluctance to pull in the Java Virtual Machine just to use Lucene but, in my experience, there's

Re: Monitoring Replication

2010-06-10 Thread Robert Newson
You can query the state of active tasks with a GET to /_active_tasks B. On Thu, Jun 10, 2010 at 2:50 PM, J Chris Anderson jch...@apache.org wrote: On Jun 10, 2010, at 2:32 AM, Moritz Post wrote: Hi List my last mail was marked to have been rejected so i resend it again. hope that it will

Re: couch lucene

2010-06-10 Thread Robert Newson
The example on the wiki page is the most trivial example. Look at the examples at http://github.com/rnewson/couchdb-lucene for less trivial ones. The reason for a Document object is that there are many different ways to index your date (different fields, numeric, date, tokenized, not tokenized,

Re: couch lucene

2010-06-10 Thread Robert Newson
. Norman On Thu, Jun 10, 2010 at 12:55 PM, Robert Newson robert.new...@gmail.com wrote: The example on the wiki page is the most trivial example. Look at the examples at http://github.com/rnewson/couchdb-lucene for less trivial ones. The reason for a Document object is that there are many

Re: Complex Keys and Ranges

2010-06-11 Thread Robert Newson
You can only query contiguous ranges of keys with startkey/endkey. [2010, 05, , , 13] is lower than [2010, 05, \u, \u, 12] and is therefore included. B. On Fri, Jun 11, 2010 at 4:46 PM, Luke Driscoll luke.drisc...@gmail.com wrote: All, I'm sorry if this question has been answered

Re: Complex Keys and Ranges

2010-06-11 Thread Robert Newson
, 12] it works as expected. I was, in fact, wrong. On Fri, Jun 11, 2010 at 11:57, Luke Driscoll luke.drisc...@gmail.comwrote: Thanks Bob, I thought it was going to be something like that.  I'll have to create separate views for this then. On Fri, Jun 11, 2010 at 11:52, Robert Newson

Re: Exception raised: {error:error,reason:eacces} on Windows

2010-06-11 Thread Robert Newson
The Futon test suite is only supported in Firefox (though it mostly works in Chrome for me). There are known limitations in the Windows release at the moment due to different file system semantics. CouchDB expects to be able to rename open files, which Linux/OSX allows but Windows does not. A

Re: Exception raised: {error:error,reason:eacces} on Windows

2010-06-11 Thread Robert Newson
CouchDB on Windows is not yet feature complete. There are issues around compaction for the reasons stated above. I don't use Windows myself, nor have I tried out the binary build you mention above, but I hope it included some kind of warning or disclaimer. I believe the intention is to have

Re: solr search?

2010-06-16 Thread Robert Newson
couchdb-lucene does not currently incorporate any of the geo- extensions, but it comes up enough that it's something I wanted to look into for 0.6. Solr has lots of extra features over lucene but is, I think, quite hard to set up right. Finally, I would use the _changes feed to keep your

Re: Tika and CouchDB Lucene

2010-06-22 Thread Robert Newson
Tika is fully integrated into couchdb-lucene. You've likely omitted one or more steps in the README, but you should have built a zip file with 'mvn', unzipped it, and run couchdb-lucene from there. the startup scripts to put all of Tika on the classpath are included. B. On Tue, Jun 22, 2010 at

Re: Tika and CouchDB Lucene

2010-06-23 Thread Robert Newson
;}       }   } } On Tue, Jun 22, 2010 at 6:43 PM, Robert Newson robert.new...@gmail.com wrote: Tika is fully integrated into couchdb-lucene. You've likely omitted one or more steps in the README, but you should have built a zip file with 'mvn', unzipped it, and run couchdb-lucene from there. the startup

Re: Fuzzy Search

2010-06-24 Thread Robert Newson
You can do fuzzy searches with couchdb-lucene; http://github.com/rnewson/couchdb-lucene B. On Thu, Jun 24, 2010 at 3:07 PM, Cory Zue c...@dimagi.com wrote: Hi again, Is there any mechanism in couchdb to do fuzzy search?  In my application I would like to be able to search for a person by

Re: html5 seeking on a couch mp3/ogg attachment

2010-06-24 Thread Robert Newson
Randall, This scratches an itch of mine also. ping me sometime if you want to collab on a patch. B. On Thu, Jun 24, 2010 at 10:31 PM, Randall Leeds randall.le...@gmail.com wrote: On Thu, Jun 24, 2010 at 16:15, Paul Bonser mister...@gmail.com wrote: On Tue, Jun 22, 2010 at 4:28 AM, Adam

Re: selecting a random subset of a view

2010-06-28 Thread Robert Newson
using skip is potentially very slow (it still has to read all the records you're skipping, so it's useful only for small skip values), suggest instead generating a random key and taking the next N from there. Whether you can fairly generate a random key is application-specific. B. On Mon, Jun

Re: selecting a random subset of a view

2010-06-28 Thread Robert Newson
If your _id's are 'aa' + sha1, then you can generate a random key as your startkey parameter to the _all_docs view. The next N hits are randomly selected. It should be clarified that map/reduce methods have to be deterministic, so approaches where you'd generate random numbers to control calls to

Re: inclusive_end howto

2010-06-28 Thread Robert Newson
the usual way to find all compound keys with the same prefix is; ?startkey=[0]endkey=[0,{}] http://wiki.apache.org/couchdb/HTTP_view_API also describes the ?inclusive_end=true/false option. B. 2010/6/28 Attila Nagy b...@fsn.hu: Hello, I have an IP space separated equally and indexed with a

Re: View Efficency

2010-06-29 Thread Robert Newson
You are correct that you cannot do map/reduce with the Lucene full-text indexing engine. People keep asking for it, but no one can explain how it could be implemented. :) B. On Tue, Jun 29, 2010 at 2:50 PM, Luke Driscoll luke.drisc...@gmail.com wrote: One of the reasons that I have not been

Re: Newbie Question about View's Startkey Match

2010-07-01 Thread Robert Newson
Afshin, Unfortunately, none of your four assumptions are correct. CouchDB supports key and key range lookup only, there is no syntax for match all arrays or match all objects. What you have probably seen is this trick; ?startkey=[foo]endkey=[foo,{}] which, in most circumstances, selects all

Re: Newbie Question about View's Startkey Match (Forked)

2010-07-01 Thread Robert Newson
You'll need to emit the last name first so that the items with the same last name sort together. function(doc) { emit([doc.lastname, doc.firstname], null); } and then query with ?startkey=[Afzali]endkey=[Afzali,{}] more simply; function(doc) { emit(doc.lastname, null); } and then query

Re: How to monitor continuous replication status?

2010-07-05 Thread Robert Newson
if _active_task would be a feed like _changes? So everyone who is interested in monitoring could simply consume the feed rather than having to poll and check for changes? On 05.07.2010, at 15:53, Robert Newson wrote: Continuous replication tasks remain in _active_tasks until they are cancelled

Re: Trying to test 1.0 artefact

2010-07-07 Thread Robert Newson
The test page reports success for each test. Some tests verify that error conditions are handled, so the log always contains some alarming error messages. Hopefully that's what happened here. Sent from my iPad On 7 Jul 2010, at 22:57, J Chris Anderson jch...@gmail.com wrote: On Jul 7, 2010,

Re: Custom view parameters???

2010-07-13 Thread Robert Newson
The full set of view querying options are documented here; http://wiki.apache.org/couchdb/HTTP_view_API#Querying_Options HTH, B. On Wed, Jul 14, 2010 at 1:19 AM, steven.prent...@nextgen.net wrote: HI I am working on a couchDB database that has a view called search_with_criteria (pretty self

Re: Custom view parameters???

2010-07-13 Thread Robert Newson
transformations would, I think, need client-side Javascript or a server-side patch. B. On Wed, Jul 14, 2010 at 1:29 AM, steven.prent...@nextgen.net wrote: Yes, I realise this. perhaps you would like to re-read my question? From: Robert Newson robert.new...@gmail.com To: user@couchdb.apache.org

Re: Test suite anomalies in 1.0.0 browser issues - firefox ok but safari hangs

2010-07-16 Thread Robert Newson
The test suite is only supported on Firefox, the issues with non-Firefox browsers are known. B. On Fri, Jul 16, 2010 at 10:30 AM, Knut Olaf Lien knut.o...@eprocess.no wrote: Fresh install of Couchdb 1.0.0 using brew. Previously testet 0.11.0 also using brew. When running the test suite,

Re: Custom / Global view functions?

2010-07-16 Thread Robert Newson
CouchApp has !code and !json macros to aid view code reuse. View functions are required to be self-contained. http://github.com/couchapp/couchapp B. On Fri, Jul 16, 2010 at 12:10 PM, A.J. Brown a...@ajbrown.org wrote: Hello fellow CouchDBians, Is there any method for writing functions which

Re: querying an array view with startkey and endkey

2010-07-21 Thread Robert Newson
http://wiki.apache.org/couchdb/HTTP_view_API#Querying_Options inclusive_end = true/false, default is true. On Wed, Jul 21, 2010 at 10:33 PM, Steven Prentice steven.prentice...@gmail.com wrote: Thanks Randall! ...I wonder why developers dont make endkey inclusive? or allow limit to specify a

Re: 1.0 windows installer

2010-07-22 Thread Robert Newson
It's worth noting that, at least in my testing, CouchDB is not working fully on Windows just yet. B. On Thu, Jul 22, 2010 at 1:04 PM, Eric Carlson e...@ericcarlson.co.uk wrote: There appears to be one already... http://people.apache.org/~mhammond/dist/1.0.0/

Re: windows - hard crash

2010-07-22 Thread Robert Newson
FWIW I've also seen hard crashes with Mark's latest (1.0) installer, the delayed_commits test hangs. Related, but not symptomatic, the Windows setup doesn't use heart (so beam.smp crashes are not recovered from). B. On Thu, Jul 22, 2010 at 6:20 PM, J Chris Anderson jch...@apache.org wrote: Yue

Re: Test-Suite (CouchDB 1.0.0) incompatible with Opera

2010-07-26 Thread Robert Newson
The test suite is currently only supported on Firefox, sorry. Patches for Opera are welcome. B. On Mon, Jul 26, 2010 at 3:03 PM, Christian Scharr christian.sch...@hsh-berlin.com wrote: Hi, I built the new 1.0 version of CouchDB from source on a Debian Linux (testing) VM. It runs smoothly

Re: external handlers are not in sync with commits

2010-07-27 Thread Robert Newson
reading _changes instead of using the (deprecated?) externals feature would avoid the problem? B. On Tue, Jul 27, 2010 at 10:37 PM, J Chris Anderson jch...@apache.org wrote: On Jul 27, 2010, at 2:30 PM, Norman Barker wrote: Hi, I have written couchdb-clucene

Re: external handlers are not in sync with commits

2010-07-27 Thread Robert Newson
and handlers are not in sync). If I am understanding you I could set up a process that listens to _changes, could I bring this process under the control of erlang as per an update notification handler? thanks, Norman On Tue, Jul 27, 2010 at 3:41 PM, Robert Newson robert.new...@gmail.com wrote

Re: Deleting databases from the Futon web interface

2010-08-03 Thread Robert Newson
You might need to send a Content-Type header of application/json if you are getting 415's. B. On Tue, Aug 3, 2010 at 10:25 AM, Aurélien Bénel aurelien.be...@utt.fr wrote: I upgraded to the trunk version this morning and I have a similar problem on database creation. Hmm, sorry. That's a

Re: Trying CouchDB / Coucdb-Lucene stack

2010-08-03 Thread Robert Newson
Did you add this to your .ini file?; [external] fti=/path/to/python /path/to/couchdb-lucene/tools/couchdb-external-hook.py [httpd_db_handlers] _fti = {couch_httpd_external, handle_external_req, fti} B. On Tue, Aug 3, 2010 at 8:21 PM, Timothy Washington timothyjwashing...@yahoo.ca wrote: Hey

Re: Trying CouchDB / Coucdb-Lucene stack

2010-08-03 Thread Robert Newson
, in raw_decode    raise ValueError(No JSON object could be decoded) ValueError: No JSON object could be decoded t...@tim-laptop:~/tmp$ Tim From: Robert Newson robert.new...@gmail.com To: user@couchdb.apache.org Sent: Tue, August 3, 2010 3:25:00 PM

Re: Trying CouchDB / Coucdb-Lucene stack

2010-08-03 Thread Robert Newson
$ From: Robert Newson robert.new...@gmail.com To: user@couchdb.apache.org Sent: Tue, August 3, 2010 4:01:57 PM Subject: Re: Trying CouchDB / Coucdb-Lucene stack you need to enter valid JSON before you hit return if you're testing the Python script directly. Entering '{}' without

Re: Data loss

2010-08-08 Thread Robert Newson
Yes there is, and it bears repeating; POSTing to /db/_ensure_full_commit will still cause a header to be written. B. On Sun, Aug 8, 2010 at 8:40 AM, Sascha Reuter s.reu...@geek-it.de wrote: Is there any way to manually trigger a commit before stopping, upgrading and restarting the server, so

Re: Cannot search single terms in Couchdb-lucene (maybe Analyzer problems)

2010-08-10 Thread Robert Newson
Can you paste the fulltext section of the related design document and also name the version of c-l you are using? Thanks, B. On Tue, Aug 10, 2010 at 8:01 PM, Timothy Washington timothyjwashing...@yahoo.ca wrote: Our team is using couchdb-lucene. We have the tool installed, configured and

Re: Cannot search single terms in Couchdb-lucene (maybe Analyzer problems)

2010-08-10 Thread Robert Newson
: 2f07e40455e,  skip: 0,  limit: 25,  total_rows: 0,  search_duration: 0,  fetch_duration: 0,  rows: [] } Tim From: Robert Newson robert.new...@gmail.com To: user@couchdb.apache.org Sent: Tue, August 10, 2010 3:47:46 PM Subject: Re: Cannot search

Re: Cannot search single terms in Couchdb-lucene (maybe Analyzer problems)

2010-08-10 Thread Robert Newson
Oh, and also output of wget http://172.16.114.129:5985/ Thanks, B. On Tue, Aug 10, 2010 at 9:13 PM, Robert Newson robert.new...@gmail.com wrote: Can you also report the result of wget 'http://172.16.114.129:5984/baron/_fti/_design/foo/by_all' please? I pushed 0.5.5 today. It (and 0.6

Re: Cannot search single terms in Couchdb-lucene (maybe Analyzer problems)

2010-08-10 Thread Robert Newson
From: Robert Newson robert.new...@gmail.com To: user@couchdb.apache.org Sent: Tue, August 10, 2010 4:30:00 PM Subject: Re: Cannot search single terms in Couchdb-lucene (maybe Analyzer problems) Oh, and also output of wget http://172.16.114.129:5985/ Thanks, B. On Tue, Aug

Re: Cannot search single terms in Couchdb-lucene (maybe Analyzer problems)

2010-08-12 Thread Robert Newson
of how you got here would help me enormously. I understand if you don't have the time. Thanks, B. On Tue, Aug 10, 2010 at 10:20 PM, Robert Newson robert.new...@gmail.com wrote: just missed you on IRC :( my nick is rnewson. B. On Tue, Aug 10, 2010 at 10:16 PM, Timothy Washington timothyjwashing

Re: CouchDB-Lucene and keys

2010-08-13 Thread Robert Newson
yes. On Fri, Aug 13, 2010 at 4:16 PM, A.J. Brown a...@ajbrown.org wrote: Hi All, Is it possible to emit keys with couchdb-lucene views, and return only documents which match the key (like standard views)?  I have a set of documents that are currently being indexed, but I need to query only a

Re: CouchDB-Lucene and keys

2010-08-13 Thread Robert Newson
. B. On Fri, Aug 13, 2010 at 5:51 PM, A.J. Brown a...@ajbrown.org wrote: Can you elaborate? :) Do I just specify a map function next to the index function, and pass the normal key|startkey|endkey query string variables along with my query? On Fri, Aug 13, 2010 at 11:19 AM, Robert Newson

Re: Struggling with a particular Map / Reduce

2010-08-17 Thread Robert Newson
If you emit([doc.docAuthor, doc.titles[title]], 1) instead you could use the built-in Erlang reduce function _sum instead, which is faster. B. On Tue, Aug 17, 2010 at 10:24 AM, Martin Higham mar...@ocasta.co.uk wrote: I think it would be better to use the View to split the titles and create a

Re: How to cancel a continuous replication task

2010-08-19 Thread Robert Newson
Did you get an {ok:true,_local_id:foo} response from the first _replicate call? I've just verified that adding cancel:true to the original _replicate setting cancels the task. Perhaps you're on an earlier version than this feature? B. On Thu, Aug 19, 2010 at 5:08 PM, Zachary Zolton

Re: What are the contents of userCtx in validators ?

2010-08-21 Thread Robert Newson
The tweak to expose the md5 of the attachment is easy, but md5 is broken for this purpose. It's fine to detect corruption, but you shouldn't sign md5 values any more. B. On Sat, Aug 21, 2010 at 6:31 PM, J Chris Anderson jch...@apache.org wrote: On Aug 21, 2010, at 12:45 AM, sgoto wrote: On

Re: Seamless view rebuilding?

2010-08-26 Thread Robert Newson
Create a new ddoc with your new view, query that view, waiting for it to build, and then copy your new ddoc over your old one. View indexes are named on disk after their digest specifically to allow this offline building feature. :) B. On Thu, Aug 26, 2010 at 2:40 PM, Patrick Barnes

Re: get couchdb to startup with server

2010-09-03 Thread Robert Newson
the couch.io .bin installer actually prompts you to read the README at the end of the installation (and defaults to Yes). It is also included in the install itself (/opt/couchdb-1.0.1, say), along with all the other docs. The only way to have not read it is to have explicitly declined to do so, I

Re: access a field of a document

2010-09-11 Thread Robert Newson
You can achieve the PUT side with an update handler and the GET side with a show function. http://wiki.apache.org/couchdb/Document_Update_Handlers http://wiki.apache.org/couchdb/Formatting_with_Show_and_List B. On Fri, Sep 10, 2010 at 11:41 PM, Dave Cottlehuber d...@muse.net.nz wrote: On 11

Re: Couch not releasing deleted files

2010-09-14 Thread Robert Newson
This was mentioned at CouchCamp, several developers suspect there's a subtle bug in the code where file descriptors are not being closed under some conditions. Did the OP identify a particular sequence that led here? B. On Mon, Sep 13, 2010 at 6:25 PM, Juan Jose Comellas jua...@comellas.org

Re: Username is case-sensative

2010-09-15 Thread Robert Newson
I notice this on my iPhone with many sites. I push the shift button in these circumstances. B. On Wed, Sep 15, 2010 at 10:00 PM, Ido Ran ido@gmail.com wrote: Hi, While testing how CouchApp works in iPhone I notice that the authentication using username and password check the user name in

Re: One-sided 1-to-many relationship

2010-09-15 Thread Robert Newson
Does this help? http://wiki.apache.org/couchdb/View_collation B. On Wed, Sep 15, 2010 at 10:10 PM, 7zark7 7za...@gmail.com wrote: Given doc type A and B: A has a 1-to-many relationship with B (each A knows of many Bs) Each B can be known by many As, but does not know which. A has an array

Re: Username is case-sensative

2010-09-16 Thread Robert Newson
The question is whether CouchDB should force everyone to do that or not. I think it should not. B. On Fri, Sep 17, 2010 at 2:23 AM, Tyler Gillies ty...@pdxbrain.com wrote: I think case insensitivity is good, prevents thing from getting complicated with two users one named tyler and one named

Re: Duplication of unique keys

2010-09-17 Thread Robert Newson
document ids are unique; you can't have duplicates, which makes the original post a little hard to understand. B. On Fri, Sep 17, 2010 at 10:23 AM, Dave Cottlehuber d...@muse.net.nz wrote: Hi Babawala If you are creating your own UUIDs or using the system generated one, doc.id should be

#couchdb-lucene

2010-09-18 Thread Robert Newson
All, I registered #couchdb-lucene on freenode today. Might be a short-lived experiment depending on community participation but the project seems to have a number of fans, it felt like time to have a place to chat about it without being spamming #couchdb. B.

Re: Couch not releasing deleted files

2010-09-18 Thread Robert Newson
to the newer versions the same identical problem happened. On 14 September 2010 14:49, Robert Newson robert.new...@gmail.com wrote: This was mentioned at CouchCamp, several developers suspect there's a subtle bug in the code where file descriptors are not being closed under some

Re: #couchdb-lucene

2010-09-19 Thread Robert Newson
I don't believe so. B. On Sun, Sep 19, 2010 at 5:24 AM, Tyler Gillies ty...@pdxbrain.com wrote: Is it available as a couchone addon yet? -- http://www.readwriteweb.com/about#tyler My website: http://list.pdxbrain.com

Re: distributed map-reduce views

2010-09-20 Thread Robert Newson
A nice explanation. I've never quite known how to respond to people that, when I discuss CouchDB with them, say why not use Hadoop?. Admittedly it's mostly because I'm trying to hold back a biting comment, since there's really no commonality besides the use of (distinct variants of) the Map/Reduce

Re: distributed map-reduce views

2010-09-20 Thread Robert Newson
, Robert Dionne dio...@dionne-associates.com wrote: On Sep 20, 2010, at 5:13 PM, Paul Davis wrote: On Mon, Sep 20, 2010 at 5:01 PM, Robert Newson robert.new...@gmail.com wrote: A nice explanation. I've never quite known how to respond to people that, when I discuss CouchDB with them, say why

Re: old db version number showing up in names- unreadable docs

2010-09-23 Thread Robert Newson
couch.uri is how the port is discovered by desktopcouch, iirc. On Thu, Sep 23, 2010 at 7:26 PM, Paul Davis paul.joseph.da...@gmail.com wrote: Right, no idea what couch.uri is, but to fix it you should just need to move what's in the 0.10.0 up one directory. If there's nothing in that directory

Re: Couchdb-lucene and readers problem

2010-09-24 Thread Robert Newson
I'm assuming you've set require_valid_user=true? If so, you need to add a user:pass value to couchdb-lucene's ini file. The details are in the README under Security. Sent from my iPad On 24 Sep 2010, at 07:53, Patrick Barnes mrtr...@gmail.com wrote: I have couchdb-lucene set up and working

Re: Time information and UUID

2010-09-26 Thread Robert Newson
There are three algorithms available from the uuid generator inside couchdb, utc_random, random and sequential. Only utc_random includes the current time thus; utc_random() - Now = {_, _, Micro} = now(), Nowish = calendar:now_to_universal_time(Now), Nowsecs =

Re: Return doc data with _changes feed?

2010-10-02 Thread Robert Newson
Since 0.11 you can add include_docs=true to your _changes query. http://wiki.apache.org/couchdb/HTTP_database_API#Changes B. On Sat, Oct 2, 2010 at 11:49 AM, Enrique Flores eflor...@gmail.com wrote: Hi, We are monitoring a database with the continuous changes API, but our bottleneck now is

Re: Cooking Views

2010-10-15 Thread Robert Newson
Boolean queries can be achieved with a different index, fed from a couchdb database. For example: http://github.com/rnewson/couchdb-lucene B. On Fri, Oct 15, 2010 at 5:29 PM, Terry Brownell terrybrown...@gmail.com wrote: Thank Mark, My initial hunch was CouchDB isn't particularly suited as a

Re: A question about compound keys

2010-10-16 Thread Robert Newson
It's startkey and endkey not start_key and end_key :) B. On Sat, Oct 16, 2010 at 12:02 PM, Tracy Flynn couc...@thisonejustforme.com wrote: Any help is appreciated. I know I'm missing something basic. What I've read indicates that the following query

Re: CouchDB-lucene windows service wrapper

2010-10-19 Thread Robert Newson
There is not currently a Windows service wrapper fror CouchDB-Lucene. I'd gladly take a patch to add one but the next release of CouchDB (1.1) includes a significant enhancement to the external handler mechanism which might make it obsolete. B. On Tue, Oct 19, 2010 at 6:23 AM, Darran White

Re: DELETE doc without rev

2010-10-19 Thread Robert Newson
it's _deleted not _delete B. On Tue, Oct 19, 2010 at 10:43 AM, Alex Ivasyuv indust...@gmail.com wrote: On 10/19/2010 04:54 PM, Johannes Jörg Schmidt wrote: You could write an update function which sets doc._delete to true. This way you can delete a document sending only one request.

Re: https?

2010-10-29 Thread Robert Newson
FYI: direct HTTPS support should arrive in CouchDB 1.1. B On Fri, Oct 29, 2010 at 9:23 AM, Cliff Williams cliffywi...@aol.com wrote: Doug, I hope you are well. Couchdb does not handle https by itself. I think that a generally acceptable method would be to put couchdb behind a reverse

Re: Setting ContentType For List Functions

2010-11-03 Thread Robert Newson
http://wiki.apache.org/couchdb/Formatting_with_Show_and_List#Specifying_Content-Type_Response_Header On Wed, Nov 3, 2010 at 1:24 AM, David Rose dopp...@gmail.com wrote: http://wiki.apache.org/couchdb/Formatting_with_Show_and_List search for example list function doppler On Tue, Nov 2, 2010

Re: Couch and Varnish

2010-11-08 Thread Robert Newson
I think it's clear that caching via ETag for documents is close to pointless (the work to find the doc in the b+tree is over 90% of the work and has to be done for GET or HEAD). Where there should be a boost is caching of attachments, since couch doesn't have to fetch one byte of the actual

Re: catalogs in CouchDB

2010-11-09 Thread Robert Newson
CouchDB uses a b+tree data structure for find and list documents. Is this the answer to your question? B. 2010/11/9 José M Martínez josemmartin...@gmail.com: HI, I mean by catalogs, a data dictionary.CouchDB used a data dictionary to find details of documents and list all documents in my

Re: How to know when CouchDB is under heavy load of document writes?

2010-11-10 Thread Robert Newson
One way to detect it is to poll /dbname and see how fast the update_seq is changing. Since you'll need one query per database, this might not be very useful in general. You can also use iostat (atop, etc, etc) to detect how hard your disks are working and use that to determine whether it's ok to

Re: Join Query View

2010-11-11 Thread Robert Newson
A reduce function must reduce the input to a smaller output. I once campaigned to rename this function to you_must_make_the_output_smaller_than_the_input but it was considered too verbose. I'm not sure I see why handling a json array with three items in it is a difficulty. Your proposed map

Re: First doc in a group?

2010-11-11 Thread Robert Newson
No, it's not a summary in the sense of map/reduce. sum or max or count are examples of reasonable reduce functions. Specifically, functions that are commutative, associative and reduce a variable sized input to a fixed sized output. What you want is to find the last document matching certain

Re: Couch and Varnish

2010-11-13 Thread Robert Newson
eager to try it out yet... Yes, that's precisely what I'd like to avoid. It's not _that_ hard of course, and Couch provides awesome entry point for the invalidation in _changes or update_notifier, but still... On 9.Nov, 2010, at 24:42 , Robert Newson wrote: I think it's clear that caching

Re: Banking Recipe

2010-11-14 Thread Robert Newson
If you really need transactions in the classical, RDBMS sense, where you need to update a bunch of related records in one atomic operation, then CouchDB is not for you. I think that's a little overstated. Instead, realize that updates to a document are atomic, and therefore you should model your

Re: Allowing specific field value updates only

2010-11-16 Thread Robert Newson
a validation function will have the current document, the proposed new document, and the user context, so it should be simple to enforce these conditions. B. On Tue, Nov 16, 2010 at 5:30 PM, Wordit Ltd wordi...@googlemail.com wrote: Can anybody think of a way to allow _user to decrease a field

Re: Couch crash report

2010-11-16 Thread Robert Newson
: Robert, I think we have this reproduced.  If you'd like to look at db files, can you provide a private email or upload point for transmitting databases and log info? Matthew On 11/15/10 at 1:21 PM, robert.new...@gmail.com (Robert Newson) wrote: Matthew, Thanks! We've tracked

Re: Couch crash report

2010-11-16 Thread Robert Newson
Also the steps to reproduce it would be very helpful! On Tue, Nov 16, 2010 at 8:48 PM, Robert Newson robert.new...@gmail.com wrote: Can you upload the big stuff to dropbox or similar and then email the password directly to me at robert.newson at gmail dot com? I'd like to share it with other

Re: Changes API and document revisions

2010-11-24 Thread Robert Newson
The _changes feed only returns the latest version of any document. If you are following it continuously, you will see each change to a document, but if you call it again, you'll see gaps. This is by design. The reason _changes and _all_docs_by_seq work the same way is because they're reading the

Re: Incremental backups

2010-11-25 Thread Robert Newson
just copy the file, there's no need to stop couchdb. Replication would be another way, of course. On Thu, Nov 25, 2010 at 11:16 AM, afters afters.m...@gmail.com wrote: hi folks, As I'm about to implement it myself, I'm curious to know how people handle incremental backups for their DB's.

Re: Incremental backups

2010-11-25 Thread Robert Newson
be append-only for this to work, but are ALL db changes indeed append only? I remember reading that updating a tree-node also updates all its ancestors (to track latest seq) and I wonder if those changes are also append only. On 25 November 2010 13:21, Robert Newson robert.new...@gmail.com

Re: Large attachments

2010-11-25 Thread Robert Newson
David, I've failed to reproduce this locally by following your instructions. My memory usage was stable (OS X). Another user has tried the test on Linux with R13 and reports stable memory usage also. Can you provide more details of the OS, hardware and the manner in which you are monitoring the

Re: Incremental backups

2010-11-25 Thread Robert Newson
You can copy the .couch file at any time and this will yield a usable snapshot of the database. B. On Thu, Nov 25, 2010 at 1:41 PM, afters afters.m...@gmail.com wrote: On 25 November 2010 14:39, Dirkjan Ochtman dirk...@ochtman.nl wrote: On Thu, Nov 25, 2010 at 13:35, afters

Re: Incremental backups

2010-11-25 Thread Robert Newson
. Maybe theoretically, I could make a roll back on any db, simply by chopping off some bytes  from the end? On 25 November 2010 14:38, Robert Newson robert.new...@gmail.com wrote: The best way to backup is via replication, in my opinion. You can do this continuously so your backup

Re: Too many open files

2010-12-01 Thread Robert Newson
look in /proc/pid/limits to see if your tweak to limits.conf works. I doubt it does. The way I increase fd limits from the miserly Linux default of 1024 is with this run script, where couchdb is launched by runit; #!/bin/bash exec 21 export HOME=dir ulimit -n 1 exec chpst -u user couchdb -f

Re: Too many open files

2010-12-01 Thread Robert Newson
ignore the '-f' bit. On Wed, Dec 1, 2010 at 6:29 PM, Robert Newson robert.new...@gmail.com wrote: look in /proc/pid/limits to see if your tweak to limits.conf works. I doubt it does. The way I increase fd limits from the miserly Linux default of 1024 is with this run script, where couchdb

Re: Too many open files

2010-12-01 Thread Robert Newson
, Robert Newson robert.new...@gmail.com wrote: look in /proc/pid/limits to see if your tweak to limits.conf works. I doubt it does. The way I increase fd limits from the miserly Linux default of 1024 is with this run script, where couchdb is launched by runit; #!/bin/bash exec 21 export HOME=dir

Re: Map/Reduce Question

2010-12-02 Thread Robert Newson
The simplest means to dedupe this is; function(keys, values, rereduce) { return values[0]; } This assumes that all values for the same key are identical, but I think that's what you're saying. B. On Thu, Dec 2, 2010 at 12:43 AM, Matthew Woodward m...@mattwoodward.com wrote: I'm catching on

Re: Map/Reduce Question

2010-12-03 Thread Robert Newson
Matthew, Your original message implied that you might have duplicates but I didn't notice that you had documents with the same key but different contents (and there isn't one in your example). You can't reduce your way out of that, I think. What you can do instead is; map: function(doc) { if

Re: Map/Reduce Question

2010-12-03 Thread Robert Newson
add group_level=1 to get the unique foo's. On Fri, Dec 3, 2010 at 9:41 AM, Robert Newson robert.new...@gmail.com wrote: Matthew, Your original message implied that you might have duplicates but I didn't notice that you had documents with the same key but different contents (and there isn't

Re: Best practices for scaling (many small databases vs. a large one)

2010-12-07 Thread Robert Newson
As another data point, I recently worked with a modest dataset (about 10 Tib) where the same choice could be made between lots of small ones and a small number of very large ones; there were two fields that were natural partitions and they differed in scope by a few orders of magnitude. I much

Re: Suppressing duplicate documents from a view query

2010-12-10 Thread Robert Newson
I seem to remember that there is a request flag that can be passed to a view query to eliminate document duplicates. I've never heard of such an option. To remove duplicate keys from a view, use a reduce function like return null and query with reduce=true. B. On Fri, Dec 10, 2010 at 2:08 PM,

Re: Getting attachments by custom field

2010-12-29 Thread Robert Newson
The _attachments object is reserved for CouchDB internal usage and does not permit extra fields. Use a custom object of your own with the same keys; { _attachments : { foo : { ... whatever ... }}, attachments: {foo: { type:invoice }} } then attachments[foo] == invoice. B. On Wed, Dec 29,

Re: Compact not completing

2010-12-31 Thread Robert Newson
Can you try this with a tagged release like 1.0.1? On Fri, Dec 31, 2010 at 3:38 PM, m...@loop.com.br wrote: Hello, Hoping for some guidance. I have a rather large (295Gb) database that was created running 1.0.x and I am pretty certain that there is no corruption - It has always been on a

Re: Compact not completing

2010-12-31 Thread Robert Newson
Some more info would help here. 1) How far did compaction get? 2) Do you have enough spare disk space? 3) What commit of 1.0.x were you running before you moved to 08d71849? B. On Fri, Dec 31, 2010 at 3:55 PM, Robert Newson robert.new...@gmail.com wrote: Can you try this with a tagged release

Re: CouchDB Document Size

2011-01-05 Thread Robert Newson
this is probably the header that's written to point to the new document (it's exactly 4k). 'trim' by compacting the database, this is an online operation and is completely safe. B. On Wed, Jan 5, 2011 at 5:01 PM, Randall Leeds randall.le...@gmail.com wrote: Are you sure this is the case? I

Re: Views, lookup by a key, then sort by another one?

2011-01-06 Thread Robert Newson
startkey=[developers]endkey=[developers,{}] is more typical, fwiw. B. On Thu, Jan 6, 2011 at 3:31 PM, He Shiming heshim...@gmail.com wrote: You could query with startkey=[developers,null]endkey=[developers,{}] Thank you both. Now I can understand a startkey/endkey pair must be used. --

Re: problems with Apache HTTP Server Proxying CouchDB

2011-01-07 Thread Robert Newson
The test suite hasn't been verified to work behind a reverse proxy. That it fails doesn't necessarily mean that things are broken in your Apache setup. B. On Fri, Jan 7, 2011 at 4:51 PM, Fabio Batalha Cunha dos Santos fabio.bata...@scielo.org wrote: Hello all! Sorry to bother again, but I'm

Re: problems with Apache HTTP Server Proxying CouchDB

2011-01-07 Thread Robert Newson
, That sounds good!! And doesn't it represents that couchdb isn't working fine, that's it? Thanks, *Fabio Batalha C. Santos* Colegiado SciELO www.scielo.org FAPESP - CNPq - BIREME - FapUNIFESP On Fri, Jan 7, 2011 at 3:31 PM, Robert Newson robert.new...@gmail.comwrote: The test suite

<    1   2   3   4   5   6   7   8   9   10   >