You are here: Foswiki>Tasks Web>Item10740 (16 Aug 2011, PaulHarvey)Edit Attach

Item10740: MongoDBPlugin breaks Foswiki unless all replicas are up

pencil
Priority: Normal
Current State: New
Released In: n/a
Target Release: n/a
Applies To: Extension
Component: MongoDBPlugin
Branches:
Reported By: PaulHarvey
Waiting For: SvenDowideit
Last Change By: PaulHarvey
Thanks to Item10725 and Item10670, I've learned that currently, if one out of three replicas are down - then Foswiki is borked. Given a request, Foswiki only responds with:

Foswiki detected an internal error - please check your Foswiki logs and webserver logs for more information.

couldn't connect to any servers listed: mongo1.example.org:27017,mongo2.example.org:27017,mongo3.example.org:27017

This happened this morning, where mongo1 was down, and mongo3 had become PRIMARY and mongo2 was SECONDARY (according to rs.status()). We were still able to perform queries on the mongo shell; so the replica set was still operational.

We need to fix this so that MongoDBPlugin is able to work without 100% of the replicas being available.

In fact I would hope that it would continue to work with only a minority of replicas available, just read-only.

It seems that stopping a replica in a mod_fcgid environment doesn't affect the wiki immediately. You need to restart apache to force MongoDBPlugin to open up new connections.

-- PaulHarvey - 13 May 2011

Should be pretty easy to reproduce if you take out a replica, and then try to save. It seems sometimes Foswiki happily keeps running (until apache restart or the perl process dies?), but any attempt to save will result in can't get db response, not connected at /usr/local/lib/perl/5.10.1/MongoDB/Cursor.pm line 232.

-- PaulHarvey - 16 May 2011

No longer urgent, as we're not using replicas. Anyway, this probably needs us to raise a task with the MongoDB driver on CPAN.

-- PaulHarvey - 16 Jul 2011

Looks like PERL-143

-- PaulHarvey - 16 Aug 2011
 

ItemTemplate edit

Summary MongoDBPlugin breaks Foswiki unless all replicas are up
ReportedBy PaulHarvey
Codebase trunk
SVN Range
AppliesTo Extension
Component MongoDBPlugin
Priority Normal
CurrentState New
WaitingFor SvenDowideit
Checkins
TargetRelease n/a
ReleasedIn n/a
Topic revision: r4 - 16 Aug 2011, PaulHarvey
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy