couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexander Shorin (JIRA)" <>
Subject [jira] [Created] (COUCHDB-1503) Missed query server and validate_doc_update funcs.
Date Tue, 26 Jun 2012 15:37:44 GMT
Alexander Shorin created COUCHDB-1503:

             Summary: Missed query server and validate_doc_update funcs.
                 Key: COUCHDB-1503
             Project: CouchDB
          Issue Type: Bug
          Components: View Server Support
    Affects Versions: 1.3
            Reporter: Alexander Shorin

CouchDB prevents any write operations due to query server fail if where is DDoc in database
with validate_doc_update function and language property that points to not existed query server

Expected behavior:
Fail with nicer message about missed query server.
Skip VDU routines in that case.

Actual behavior:
Error: EXIT {{badmatch,[]}, [{couch_query_servers,new_process,3, [{file,"couch_query_servers.erl"},{line,478}]},
{couch_query_servers,lang_proc,3, [{file,"couch_query_servers.erl"},{line,468}]}, {couch_query_servers,handle_call,3,
[{file,"couch_query_servers.erl"},{line,328}]}, {gen_server,handle_msg,5,[{file,"gen_server.erl"},{line,588}]},

CouchDB allows to specify custom query servers and there are many of them: javascript, python,
erlang, php, ruby, clojure and more. While any custom things are outside of CouchDB domain,
there is edge case then they makes a sense. 

>From some point of data consistency, that is right behavior, because docs should be validated
before they be putted into database. VDU fails - no data, VDU passes - data are in. Case,
when VDU fails because there is no query servers that could proceed it, looks right from that
side. (Probably, they should fail with more nicer message). Missed query server is configuration
error and any other design functions stops workings as well, but they do that without any
additional behavior for base CouchDB operations(doc save is it). That's right position for
developer and database designer.

>From point of data spreading that is bad behavior, because I, as database user, could
not just replicate data from server to my own local sandbox. I also have to find right query
server or remove any DDocs(or just VDU func from them) or use some mocked solution. Fine,
but I do not care about all your ruby couchapps! I just want to handle my own data and just
work with them in my own way. Quite emotional, but position for end user is right as data
holder(in most cases).


I couldn't count this issue as real issue, due to it has quite fine workarounds as:
1. Filtered replication that removes ddocs for missed query server.
2. Client side scripting.
3. Providing well service that allows not only to replicate user data, but to setup right
environment with less pain.

But all of them are additional steps that should be made. So what do you think about this

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message