[MB-4626] couch_set_view,handle_info,\n [{'DOWN' error when user changes the design_doc during rebalance and runs the view query Created: 11/Jan/12  Updated: 09/Jan/13  Resolved: 24/Jan/12

Status: Closed
Project: Couchbase Server
Component/s: ns_server, view-engine
Affects Version/s: 2.0-developer-preview-3
Fix Version/s: 2.0-developer-preview-4
Security Level: Public

Type: Bug Priority: Blocker
Reporter: Farshid Ghods (Inactive) Assignee: Tommie McAfee
Resolution: Fixed Votes: 0
Labels: 2.0-dev-preview-4-release-notes
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: Zip Archive log-1-15.zip    

 Description   
steps to reproduce

start cluster_run -n4

run mcsodea
python pytests/performance/mcsoda.py memcached-binary://127.0.0.1:12001 json=1 doc-gen=0 doc-cache=0 max-items=10000

when the load is running rebalance in a new node and then modify the view during rebalance

log is also attached



 Comments   
Comment by Farshid Ghods (Inactive) [ 11/Jan/12 ]
"error":"{{nocatch,shutdown},\n [{couch_set_view,get_group,3},\n {couch_set_view,get_map_view,5},\n {couch_view_merger,prepare_set_view,4},\n {couch_view_merger,map_set_view_folder,5}]}","reason":"{gen_server,call,[<0.19415.5>,pop,infinity]}"}



[error_logger:error] [2012-01-11 13:15:26] [n_3@10.17.11.108:error_logger:ale_error_logger_handler:log_report:72]
=========================SUPERVISOR REPORT=========================
     Supervisor: {local,couch_secondary_services}
     Context: child_terminated
     Reason: {function_clause,
                     [{couch_set_view,handle_info,
                          [{'DOWN',#Ref<0.0.195.244933>,process,<0.492.6>,
                               {badmatch,
                                   {error,
                                       {{badmatch,{not_found,no_db_file}},
                                        [{couch_db_set,'-init/1-fun-0-',4},
                                         {lists,foldl,3},
                                         {couch_db_set,init,1},
                                         {gen_server,init_it,6},
                                         {proc_lib,init_p_do_apply,3}]}}}},
                           {server,
                               "/space/repo/couchbase-2.0/ns_server/couch/3",
Comment by Filipe Manana [ 11/Jan/12 ]
That seems to be caused by another error that precedes it.
This other error was corrected in the following commit:

https://github.com/couchbase/couchdb/commit/75a904c093e89d12bec86f3f46b390a30e6ba27f

(merged today some hours ago)
Comment by Steve Yen [ 24/Jan/12 ]
Marking this Resolved on behalf of Filipe, based on his last comment.

Filipe, if that's incorrect, please do reopen. Thanks!
Comment by Filipe Manana [ 24/Jan/12 ]
Steve, correct.
I just improved the error handling for these cases, to ensure the caller (ns_server) always gets a reply (instead of hanging) and a more helpful error/message like for e.g.:

{db_open_error,
    <<"default/0">>,
    {not_found,no_db_file},
    <<"Couldn't open database `default/0`, reason: {not_found,no_db_file}">>},

The gerrit change: http://review.couchbase.org/#change,12600
Generated at Tue Sep 02 18:16:20 CDT 2014 using JIRA 5.2.4#845-sha1:c9f4cc41abe72fb236945343a1f485c2c844dac9.