Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 10170 invoked from network); 8 Feb 2011 17:20:59 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 8 Feb 2011 17:20:59 -0000 Received: (qmail 88501 invoked by uid 500); 8 Feb 2011 17:20:58 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 88213 invoked by uid 500); 8 Feb 2011 17:20:54 -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 88196 invoked by uid 99); 8 Feb 2011 17:20:53 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 Feb 2011 17:20:53 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of rpettefar@gpslsolutions.com designates 207.5.75.31 as permitted sender) Received: from [207.5.75.31] (HELO mail31.intermedia.net) (207.5.75.31) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 Feb 2011 17:20:43 +0000 Received: from [192.168.1.201] (host62-172-85-17.range62-172.btcentralplus.com [62.172.85.17]) (Authenticated sender: rpettefar@gpslsolutions.com) by mail31.intermedia.net (Postfix) with ESMTP id A0742A7071 for ; Tue, 8 Feb 2011 09:20:19 -0800 (PST) Message-ID: <4D517B48.4060004@gpslsolutions.com> Date: Tue, 08 Feb 2011 17:20:08 +0000 From: Rob Pettefar User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-GB; rv:1.9.2.8) Gecko/20100802 Lightning/1.0b2 Thunderbird/3.1.2 MIME-Version: 1.0 To: user@couchdb.apache.org Subject: Views crash Content-Type: multipart/alternative; boundary="------------060206030601010607050902" --------------060206030601010607050902 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Hi guys I have an issue with views crashing. This has occurred on both Linux and Windows distributions of CouchDB 1.0.1 Sometimes the views for a particular database will break. In Futon they appear unresponsive. The only way round this that I have seen is to delete and rebuild the view file for the database in question. This seems to happen more often on the Windows version but I don't think it is anything to do with the >4Gb file issue. Any help you could lend would be invaluable. Thanks Rob I have included the error that was logged in the couchdb log file: [Fri, 21 Jan 2011 12:18:28 GMT] [debug] [<0.738.0>] Exit from linked pid: {<0.742.0>, {timeout, {gen_server,call, [couch_query_servers, {get_proc,<<"javascript">>}]}}} [Fri, 21 Jan 2011 12:18:28 GMT] [error] [<0.738.0>] ** Generic server <0.738.0> terminating ** Last message in was {'EXIT',<0.742.0>, {timeout, {gen_server,call, [couch_query_servers, {get_proc,<<"javascript">>}]}}} ** When Server state == {group_state,undefined,<<"testdb">>, {"../var/lib/couchdb",<<"testdb">>, {group, <<166,184,63,42,190,3,207,140,145,79,103,251,0,220, 240,226>>, nil,nil,<<"_design/testdb">>,<<"javascript">>,[], [{view,0, [<<"recent-items">>], <<"/** \n * View: recent-items\n * A list of recently added items.\n * Possibly Obsolete\n */\nfunction(doc) {\n if (doc.created_at) {\n emit(doc.created_at, doc);\n }\n};">>, nil,[],[]}, {view,1, [<<"ReportJobs">>], <<"/** \r\n * View: ReportJobs\r\n * Reporting function map. \r\n * Allow basic customer/job/page display\r\n * Changed 7th Dec 2010 - don't believed this is used\r\n */\r\nfunction(doc)\r\n{\r\n\tvar docType = doc.type.toLowerCase();\r\n\t\r\n\tif( docType == 'job'){\r\n\t\temit([doc.customer, doc.jobname, 0, 0], doc);\t\r\n\t\t\r\n\t} else if ( docType == 'page'){\r\n\t\t\r\n\t\t// Add order job before page\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji) ji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\temit([doc.customer, doc.jobname, ji, 1], doc);\r\n\t}\r\n}">>, nil,[],[]}, {view,2, [<<"archive">>], <<"/** \r\n * View: archive\r\n * Get all documents of a job name chosen in the key for archiving and restoring\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() != 'user'){\r\n\t\t\r\n\t\temit(doc.jobname, doc);\r\n\t}\r\n}">>, nil,[],[]}, {view,3, [<<"clear">>], <<"/** \r\n * View: clear\r\n * Return a list of all things so we can delete them all\r\n */\r\nfunction(doc)\r\n{\t\r\n\tvar docType = doc.type.toLowerCase();\r\n\tif(docType == 'job' || docType == 'npc' || docType == 'cpc' || docType == 'txt' || docType == 'page' || docType == 'style' || docType == 'tag')\r\n\t\temit(doc._id, doc._rev);\r\n}">>, nil,[],[]}, {view,4, [<<"cpc">>], <<"/** \r\n * View: cpc\r\n * For all documents of type 'job' and 'page', return all the data ordered by job name and job index.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'cpc'){\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit([doc.jobname, ji], doc);\r\n\t}\r\n}">>, nil,[],[]}, {view,5, [<<"document">>], <<"/** \r\n * View: document\r\n * Return a list of job documents ordered by the job name\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job'){\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit(doc.jobname, doc);\r\n\t}\r\n}">>, nil,[],[]}, {view,6, [<<"job">>], <<"/** \r\n * View: joblist\r\n * Check if a document is of type 'job'. If so, The job and order by job name\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job')\r\n\t\temit(doc.jobname, doc);\r\n}">>, nil,[],[]}, {view,7, [<<"joblist">>], <<"/** \r\n * View: joblist\r\n * Check if a document is of type 'job'. If so, return its id and job name\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job')\r\n\t\temit(doc._id, doc.jobname);\r\n}">>, nil,[],[]}, {view,8, [<<"jobrevlevels">>], <<"/** \r\n * View: jobrevlevels\r\n * Return a list of jobs and their revision levels\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job')\r\n\t\temit(doc.jobname, doc.revlevels);\r\n}">>, nil,[],[]}, {view,9, [<<"npc">>], <<"/** \r\n * View: npc\r\n * For all documents of type 'job' and 'page', return all the data ordered by job name and job index.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'npc'){\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit([doc.jobname, ji], doc);\r\n\t}\r\n}">>, nil,[],[]}, {view,10, [<<"page">>], <<"/** \r\n * View: page\r\n * Select all page documents and output them ordered by the job name and page number\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'page'){\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit([doc.jobname, ji], doc);\r\n\t}\r\n}">>, nil,[],[]}, {view,11, [<<"pagearraylist">>], <<"/** \r\n * View: pagearraylist\r\n * Select all page documents and output a summary containing the page number, section ID and status, ordered by the job name\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job' || doc.type.toLowerCase() == 'page')\r\n\t{\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\temit(doc.jobname, {\"jobindex\" : ji, \"sectionID\" : doc.sectionID, \"status\" : doc.status });\r\n\t}\r\n}">>, nil,[],[]}, {view,12, [<<"pagelist">>], <<"/** \r\n * View: pagelist\r\n * Return the job index for all documents of type 'page' that have a specific job name. \r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'page')\r\n\t{\r\n\t\tvar batch = ( doc.batch == undefined ) ? \"NONE\" : doc.batch;\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit(doc.jobname,{ \"jobindex\": doc.jobindex , \"sectionID\" : doc.sectionID , \"status\" : doc.status , \"batch\" : batch, \"table\" : doc.table});\r\n\t}\r\n}">>, nil,[],[]}, {view,13, [<<"pages">>], <<"/** \r\n * View: pages\r\n * For all documents of type 'job' and 'page', return all the data ordered by job name and job index.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job' || doc.type.toLowerCase() == 'page')\r\n\t{\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit({\"jobname\" : doc.jobname, \"jobindex\" : ji},{ \"jobindex\": doc.jobindex, \"data\" : doc.data });\r\n\t}\r\n}">>, nil,[],[]}, {view,14, [<<"pagesarray">>], <<"/** \r\n * View: pagesarray\r\n * Pages map function but converting page index to an array.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job' || doc.type.toLowerCase() == 'page')\r\n\t{\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit({\"jobname\" : doc.jobname, \"jobindex\" : ji},{ \"jobindex\": doc.jobindex, \"data\" : doc.data });\r\n\t}\r\n}">>, nil,[],[]}, {view,15, [<<"style">>], <<"/** \r\n * View: style\r\n * Return the Style doc that have a specific style name job name. \r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'style')\r\n\t{\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit(doc.stylename,doc);\r\n\t}\r\n}">>, nil,[],[]}, {view,16, [<<"stylelist">>], <<"/** \r\n * View: stylelist\r\n * Check if a document is of type 'job'. If so, return its id and job name.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'style')\r\n\t\temit(doc._id, doc.stylename);\r\n}">>, nil,[],[]}, {view,17, [<<"tag">>], <<"/** \r\n * View: tag\r\n * Check if a document is of type 'tag'. Return the document ordered by the document name\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == \"tag\")\r\n\t{\r\n\t\temit(doc.name, doc);\r\n\t}\r\n};">>, nil,[],[]}, {view,18, [<<"txt">>], <<"/** \r\n * View: txt\r\n * For all documents of type 'job' and 'page', return all the data ordered by job name and job index.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'txt'){\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit([doc.jobname, ji], doc);\r\n\t}\r\n}">>, nil,[],[]}, {view,19, [<<"user">>], <<"/** \r\n * View: txt\r\n * Select all documents of type 'user' and output the user name, password and user levels ordered by the document ID.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'user'){\r\n\t\temit(doc._id, {\"username\" : doc.username, \r\n\t\t\t\t\t \"password\" : doc.password, \r\n\t\t\t\t\t \"user_level_user\" : doc.user_level_user, \r\n\t\t\t\t\t \"user_level_dev\" : doc.user_level_dev, \r\n\t\t\t\t\t \"user_level_admin\" : doc.user_level_admin});\r\n\t}\r\n}">>, nil,[],[]}], nil,0,0,nil,nil}}, {group, <<166,184,63,42,190,3,207,140,145,79,103,251,0,220, 240,226>>, {db,<0.173.0>,<0.174.0>,nil,<<"1295611751291001">>, <0.171.0>,<0.176.0>, {db_header,5,32387,0, {375680498,{11560,19361}}, {375682738,30921}, {370499732,[]}, 0,nil,nil,1000}, 32387, {btree,<0.171.0>, {375680498,{11560,19361}}, #Fun, #Fun, #Fun, #Fun}, {btree,<0.171.0>, {375682738,30921}, #Fun, #Fun, #Fun, #Fun}, {btree,<0.171.0>, {370499732,[]}, #Fun, #Fun, #Fun,nil}, 32387,<<"testdb">>, "../var/lib/couchdb/testdb.couch",[],[],nil, {user_ctx,null,[],undefined}, nil,1000, [before_header,after_header,on_file_open], false}, <0.740.0>,<<"_design/testdb">>,<<"javascript">>,[], [{view,0, [<<"recent-items">>], <<"/** \n * View: recent-items\n * A list of recently added items.\n * Possibly Obsolete\n */\nfunction(doc) {\n if (doc.created_at) {\n emit(doc.created_at, doc);\n }\n};">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,1, [<<"ReportJobs">>], <<"/** \r\n * View: ReportJobs\r\n * Reporting function map. \r\n * Allow basic customer/job/page display\r\n * Changed 7th Dec 2010 - don't believed this is used\r\n */\r\nfunction(doc)\r\n{\r\n\tvar docType = doc.type.toLowerCase();\r\n\t\r\n\tif( docType == 'job'){\r\n\t\temit([doc.customer, doc.jobname, 0, 0], doc);\t\r\n\t\t\r\n\t} else if ( docType == 'page'){\r\n\t\t\r\n\t\t// Add order job before page\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji) ji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\temit([doc.customer, doc.jobname, ji, 1], doc);\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,2, [<<"archive">>], <<"/** \r\n * View: archive\r\n * Get all documents of a job name chosen in the key for archiving and restoring\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() != 'user'){\r\n\t\t\r\n\t\temit(doc.jobname, doc);\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,3, [<<"clear">>], <<"/** \r\n * View: clear\r\n * Return a list of all things so we can delete them all\r\n */\r\nfunction(doc)\r\n{\t\r\n\tvar docType = doc.type.toLowerCase();\r\n\tif(docType == 'job' || docType == 'npc' || docType == 'cpc' || docType == 'txt' || docType == 'page' || docType == 'style' || docType == 'tag')\r\n\t\temit(doc._id, doc._rev);\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,4, [<<"cpc">>], <<"/** \r\n * View: cpc\r\n * For all documents of type 'job' and 'page', return all the data ordered by job name and job index.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'cpc'){\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit([doc.jobname, ji], doc);\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,5, [<<"document">>], <<"/** \r\n * View: document\r\n * Return a list of job documents ordered by the job name\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job'){\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit(doc.jobname, doc);\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,6, [<<"job">>], <<"/** \r\n * View: joblist\r\n * Check if a document is of type 'job'. If so, The job and order by job name\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job')\r\n\t\temit(doc.jobname, doc);\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,7, [<<"joblist">>], <<"/** \r\n * View: joblist\r\n * Check if a document is of type 'job'. If so, return its id and job name\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job')\r\n\t\temit(doc._id, doc.jobname);\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,8, [<<"jobrevlevels">>], <<"/** \r\n * View: jobrevlevels\r\n * Return a list of jobs and their revision levels\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job')\r\n\t\temit(doc.jobname, doc.revlevels);\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,9, [<<"npc">>], <<"/** \r\n * View: npc\r\n * For all documents of type 'job' and 'page', return all the data ordered by job name and job index.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'npc'){\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit([doc.jobname, ji], doc);\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,10, [<<"page">>], <<"/** \r\n * View: page\r\n * Select all page documents and output them ordered by the job name and page number\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'page'){\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit([doc.jobname, ji], doc);\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,11, [<<"pagearraylist">>], <<"/** \r\n * View: pagearraylist\r\n * Select all page documents and output a summary containing the page number, section ID and status, ordered by the job name\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job' || doc.type.toLowerCase() == 'page')\r\n\t{\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\temit(doc.jobname, {\"jobindex\" : ji, \"sectionID\" : doc.sectionID, \"status\" : doc.status });\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,12, [<<"pagelist">>], <<"/** \r\n * View: pagelist\r\n * Return the job index for all documents of type 'page' that have a specific job name. \r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'page')\r\n\t{\r\n\t\tvar batch = ( doc.batch == undefined ) ? \"NONE\" : doc.batch;\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit(doc.jobname,{ \"jobindex\": doc.jobindex , \"sectionID\" : doc.sectionID , \"status\" : doc.status , \"batch\" : batch, \"table\" : doc.table});\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,13, [<<"pages">>], <<"/** \r\n * View: pages\r\n * For all documents of type 'job' and 'page', return all the data ordered by job name and job index.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job' || doc.type.toLowerCase() == 'page')\r\n\t{\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit({\"jobname\" : doc.jobname, \"jobindex\" : ji},{ \"jobindex\": doc.jobindex, \"data\" : doc.data });\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,14, [<<"pagesarray">>], <<"/** \r\n * View: pagesarray\r\n * Pages map function but converting page index to an array.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'job' || doc.type.toLowerCase() == 'page')\r\n\t{\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit({\"jobname\" : doc.jobname, \"jobindex\" : ji},{ \"jobindex\": doc.jobindex, \"data\" : doc.data });\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,15, [<<"style">>], <<"/** \r\n * View: style\r\n * Return the Style doc that have a specific style name job name. \r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'style')\r\n\t{\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit(doc.stylename,doc);\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,16, [<<"stylelist">>], <<"/** \r\n * View: stylelist\r\n * Check if a document is of type 'job'. If so, return its id and job name.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'style')\r\n\t\temit(doc._id, doc.stylename);\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,17, [<<"tag">>], <<"/** \r\n * View: tag\r\n * Check if a document is of type 'tag'. Return the document ordered by the document name\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == \"tag\")\r\n\t{\r\n\t\temit(doc.name, doc);\r\n\t}\r\n};">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,18, [<<"txt">>], <<"/** \r\n * View: txt\r\n * For all documents of type 'job' and 'page', return all the data ordered by job name and job index.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'txt'){\r\n\t\t\r\n\t\t// Split up job index into an array\r\n\t\tvar ji = doc.jobindex.split('.');\r\n\t\t\r\n\t\t// Convert from strings to numbers\r\n\t\tfor (i in ji)\r\n\t\t\tji[i] = parseInt(ji[i]);\r\n\t\t\r\n\t\t// JN: Changed for test but now this can be extended as required so good change\r\n\t\temit([doc.jobname, ji], doc);\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}, {view,19, [<<"user">>], <<"/** \r\n * View: txt\r\n * Select all documents of type 'user' and output the user name, password and user levels ordered by the document ID.\r\n */\r\nfunction(doc)\r\n{\r\n\tif(doc.type.toLowerCase() == 'user'){\r\n\t\temit(doc._id, {\"username\" : doc.username, \r\n\t\t\t\t\t \"password\" : doc.password, \r\n\t\t\t\t\t \"user_level_user\" : doc.user_level_user, \r\n\t\t\t\t\t \"user_level_dev\" : doc.user_level_dev, \r\n\t\t\t\t\t \"user_level_admin\" : doc.user_level_admin});\r\n\t}\r\n}">>, {btree,<0.740.0>,nil, #Fun, #Fun, #Fun, #Fun}, [],[]}], {btree,<0.740.0>,nil,#Fun, #Fun, #Fun,nil}, 0,0,nil,nil}, <0.742.0>,nil,false, [{{<0.728.0>,#Ref<0.0.0.60542>},32387}], <0.743.0>} ** Reason for termination == ** {timeout,{gen_server,call, [couch_query_servers,{get_proc,<<"javascript">>}]}} [Fri, 21 Jan 2011 12:18:28 GMT] [error] [<0.738.0>] {error_report,<0.33.0>, {<0.738.0>,crash_report, [[{initial_call,{couch_view_group,init,['Argument__1']}}, {pid,<0.738.0>}, {registered_name,[]}, {error_info, {exit, {timeout, {gen_server,call, [couch_query_servers,{get_proc,<<"javascript">>}]}}, [{gen_server,terminate,6},{proc_lib,init_p_do_apply,3}]}}, {ancestors, [couch_view,couch_secondary_services,couch_server_sup,<0.34.0>]}, {messages,[]}, {links,[<0.740.0>,<0.103.0>]}, {dictionary,[]}, {trap_exit,true}, {status,running}, {heap_size,2584}, {stack_size,24}, {reductions,855}], []]}} [Fri, 21 Jan 2011 12:18:28 GMT] [debug] [<0.728.0>] request_group Error {timeout, {gen_server,call, [couch_query_servers, {get_proc,<<"javascript">>}]}} [Fri, 21 Jan 2011 12:18:28 GMT] [error] [<0.740.0>] ** Generic server <0.740.0> terminating ** Last message in was {'EXIT',<0.738.0>, {timeout, {gen_server,call, [couch_query_servers, {get_proc,<<"javascript">>}]}}} ** When Server state == {file,{file_descriptor,prim_file,{#Port<0.4047>,596}}, 0,51} ** Reason for termination == ** {timeout,{gen_server,call, [couch_query_servers,{get_proc,<<"javascript">>}]}} [Fri, 21 Jan 2011 12:18:28 GMT] [error] [<0.740.0>] {error_report,<0.33.0>, {<0.740.0>,crash_report, [[{initial_call,{couch_file,init,['Argument__1']}}, {pid,<0.740.0>}, {registered_name,[]}, {error_info, {exit, {timeout, {gen_server,call, [couch_query_servers,{get_proc,<<"javascript">>}]}}, [{gen_server,terminate,6},{proc_lib,init_p_do_apply,3}]}}, {ancestors, [<0.738.0>,couch_view,couch_secondary_services,couch_server_sup, <0.34.0>]}, {messages,[]}, {links,[#Port<0.4047>,<0.743.0>]}, {dictionary,[]}, {trap_exit,true}, {status,running}, {heap_size,610}, {stack_size,24}, {reductions,1435}], [{neighbour, [{pid,<0.743.0>}, {registered_name,[]}, {initial_call,{couch_ref_counter,init,['Argument__1']}}, {current_function,{gen_server,loop,6}}, {ancestors, [<0.738.0>,couch_view,couch_secondary_services, couch_server_sup,<0.34.0>]}, {messages, [{'DOWN',#Ref<0.0.0.60538>,process,<0.738.0>, {timeout, {gen_server,call, [couch_query_servers, {get_proc,<<"javascript">>}]}}}]}, {links,[<0.740.0>]}, {dictionary,[]}, {trap_exit,false}, {status,runnable}, {heap_size,233}, {stack_size,9}, {reductions,47}]}]]}} --------------060206030601010607050902--