Item10664: Having trouble getting MongoDB to notice newly created webs - i.e. it seems I have to explicitly load a web before the DB gets created for it
Priority: Normal
Current State: Closed
Released In: n/a
Target Release: n/a
I'd love a less vague description, but I'm assuming that you mean you create a new web via the Func api?
and I'm hoping that your listeners are functioning correctly....
--
SvenDowideit - 21 Apr 2011
When I use the
ManagingWebs UI to create a web, Eg.
Sandbox.TestWeb
, it times out and fcgid kills the process (returns error 500 to the browser).
Watching top, I can see memory usage grow and grow up to 1GB before the fcgid timeout kills it off.
My
LocalSite.cfg contained the following:
$Foswiki::cfg{Store}{Implementation} = 'Foswiki::Store::RcsWrap';
$Foswiki::cfg{Store}{SearchAlgorithm} = 'Foswiki::Store::SearchAlgorithms::Forking';
$Foswiki::cfg{Store}{EgrepCmd} = '/bin/grep -E %CS{|-i}% %DET{|-l}% -H -- %TOKEN|U% %FILES|F%';
$Foswiki::cfg{Store}{FgrepCmd} = '/bin/grep -F %CS{|-i}% %DET{|-l}% -H -- %TOKEN|U% %FILES|F%';
$Foswiki::cfg{Store}{QueryAlgorithm} = 'Foswiki::Store::QueryAlgorithms::BruteForce';
$Foswiki::cfg{Store}{PrefsBackend} = 'Foswiki::Prefs::TopicRAM';
$Foswiki::cfg{Store}{Listeners} = {'Foswiki::Plugins::MongoDBPlugin::Listener' => 1};
$Foswiki::cfg{Plugins}{MongoDBPlugin}{Enabled} = 1;
$Foswiki::cfg{Plugins}{MongoDBPlugin}{Module} = 'Foswiki::Plugins::MongoDBPlugin';
$Foswiki::cfg{MongoDBPlugin}{host} = 'a.wiki.org:27017,b.wiki.org:27017,c.wiki.org:27017';
$Foswiki::cfg{MongoDBPlugin}{auto_reconnect} = 1;
$Foswiki::cfg{MongoDBPlugin}{auto_connect} = 1;
$Foswiki::cfg{MongoDBPlugin}{timeout} = 20000;
$Foswiki::cfg{MongoDBPlugin}{find_master} = 1;
$Foswiki::cfg{MongoDBPlugin}{w} = 1;
$Foswiki::cfg{MongoDBPlugin}{wtimeout} = 1000;
$Foswiki::cfg{MongoDBPlugin}{username} = '';
$Foswiki::cfg{MongoDBPlugin}{password} = '';
$Foswiki::cfg{Plugins}{MongoDBPlugin}{ExperimentalCode} = 1;
Please note the "use of unitialised..." errors in the
apache error log.
--
PaulHarvey - 22 Apr 2011
Hrm. After setting Search & QueryAlgorith to MongODB (rather than Forking/!BruteForce), the create web function now works. The memory usage is still somewhat concerning, but I might also throw in:
- I was hitting 'back' and re-submitting the create new web page, so maybe it was struggling in the code which generates an CSRF validation error?
- What kind of search happens when you create a new web - maybe this occurs on our configuration & webs with Forking/BruteForce because they are too slow?
--
PaulHarvey - 22 Apr 2011
Anyway, apart from the above glitch, it seems my problem was caused by incorrect listener config. It works now.
--
PaulHarvey - 22 Apr 2011
so can we close it? wrt csrf, no idea, er, nope, noidea
--
SvenDowideit - 23 Apr 2011
Let's close it
--
PaulHarvey - 23 Apr 2011