couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Okstad <poks...@gmail.com>
Subject Tweaking CouchDB For DB-Per-User
Date Sun, 11 Jan 2015 23:24:17 GMT
Howdy All,

I would really appreciate help from anyone experienced with running a server with database-per-user
configuration.

I have a server with about 1000 users and growing and I’m using a database per user to maintain
privacy of data. I also have all databases replicating to a global database so that I can
easily replicate the all data to another server and do views across users. I’ve noticed
that some of the replications are failing. Here’s a sample error:

[Sun, 11 Jan 2015 21:05:05 GMT] [error] [<0.88.0>] {error_report,<0.31.0>,
                    {<0.88.0>,supervisor_report,
                     [{supervisor,{local,couch_replicator_job_sup}},
                      {errorContext,child_terminated},
                      {reason,
                       {{{case_clause,
                          {{badmatch,{error,emfile}},
                           [{couch_file,init,1,
                             [{file,"couch_file.erl"},{line,314}]},
                            {gen_server,init_it,6,
                             [{file,"gen_server.erl"},{line,306}]},
                            {proc_lib,init_p_do_apply,3,
                             [{file,"proc_lib.erl"},{line,239}]}]}},
                         [{couch_server,handle_info,2,
                           [{file,"couch_server.erl"},{line,442}]},
                          {gen_server,handle_msg,5,
                           [{file,"gen_server.erl"},{line,599}]},
                          {proc_lib,init_p_do_apply,3,
                           [{file,"proc_lib.erl"},{line,239}]}]},
                        {gen_server,call,
                         [couch_server,
                          {open,<<“user1_database">>,
                           [{user_ctx,
                             {user_ctx,<<“admin_username">>,
                              [<<"_admin">>],
                              undefined}}]},
                          infinity]}}},
                      {offender,
                       [{pid,<0.16660.0>},
                        {name,"e93a43abfd0dbe11ea68891c7cfce253+continuous"},
                        {mfargs,{gen_server,start_link,undefined}},
                        {restart_type,temporary},
                        {shutdown,250},
                        {child_type,worker}]}]}}

I was under the impression that replication between databases on the same server was a lightweight
task compared to external replication. Hopefully a solution can be found because other than
this issue, it is working great!

- Paul
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message