php - Can't connect to mongoDB with lithium -


i have uncomented mongodb connection in bootstrap/connections.php , seems ok i'm getting following error:

( ! ) fatal error: uncaught exception 'lithium\core\networkexception' message 'could not connect database.' in c:\wamp\www\libraries\lithium\data\source\mongodb.php on line 792     ( ! ) lithium\core\networkexception: not connect database. in c:\wamp\www\libraries\lithium\data\source\mongodb.php on line 792     call stack     #   time    memory  function    location     1   0.0004  370296  {main}( )   ..\index.php:0     2   0.0328  2618640 lithium\action\dispatcher::run( )   ..\index.php:36     3   0.0328  2619848 lithium\core\staticobject::_filter( )   ..\dispatcher.php:122     4   0.0329  2621472 lithium\util\collection\filters::run( ) ..\staticobject.php:128     5   0.0330  2623800 {closure}( )    ..\filters.php:182     6   0.0397  2692456 lithium\util\collection\filters->next( )    ..\cache.php:47     7   0.0397  2692488 {closure}( )    ..\filters.php:201     8   0.0428  2720784 lithium\util\collection\filters->next( )    ..\action.php:52     9   0.0428  2720816 lithium\action\{closure}( ) ..\filters.php:201     10  0.0448  2756432 lithium\core\staticobject::invokemethod( )  ..\dispatcher.php:121     11  0.0448  2756464 lithium\action\dispatcher::_call( ) ..\staticobject.php:74     12  0.0449  2757552 lithium\core\staticobject::_filter( )   ..\dispatcher.php:203     13  0.0449  2757808 lithium\action\{closure}( ) ..\staticobject.php:121     14  0.0449  2757808 lithium\action\controller->__invoke( )  ..\dispatcher.php:200     15  0.0449  2759408 lithium\core\object->_filter( ) ..\controller.php:184     16  0.0449  2759688 lithium\action\{closure}( ) ..\object.php:245     17  0.0450  2759936 lithium\core\object->invokemethod( )    ..\controller.php:172     18  0.0450  2759968 app\controllers\postscontroller->add( ) ..\object.php:167     19  0.0643  3862976 lithium\data\entity\document->save( )   ..\postscontroller.php:25     20  0.0643  3863176 lithium\data\entity->__call( )  ..\entity.php:0     21  0.0644  3863672 call_user_func_array ( )    ..\entity.php:197     22  0.0644  3863936 lithium\data\model->save( ) ..\entity.php:0     23  0.0644  3867352 lithium\data\model::_filter( )  ..\model.php:719     24  0.0645  3867608 lithium\core\staticobject::_filter( )   ..\model.php:891     25  0.0645  3867728 lithium\data\{closure}( )   ..\staticobject.php:121     26  0.0723  4182168 lithium\data\source\mongodb->create( )  ..\model.php:713     27  0.0723  4182168 lithium\data\source\mongodb->_checkconnection( )    ..\mongodb.php:346 

seems kinda weird issue me. exact following lithium blog tutorial.

edit adding mongo db configuration phpinfo()

mongo mongodb support enabled version     1.1.3  directive   local value master value mongo.allow_empty_keys  0   0 mongo.allow_persistent  1   1 mongo.auto_reconnect    1   1 mongo.chunk_size    262144  262144 mongo.cmd   $   $ mongo.default_host  localhost   localhost mongo.default_port  27017   27017 mongo.long_as_object    0   0 mongo.native_long   0   0 mongo.no_id 0   0 mongo.utf8  1   1 

make sure you're running latest git master of lithium. last release version 0.9.9, , mongo pecl extension has made 3 major bc-breaking changes since then. they're fixed in core, haven't been rolled release yet. also, user name , password not mandatory.


Comments

Popular posts from this blog

python - Scipy curvefit RuntimeError:Optimal parameters not found: Number of calls to function has reached maxfev = 1000 -

c# - How to add a new treeview at the selected node? -

java - netbeans "Please wait - classpath scanning in progress..." -