简体   繁体   English

部署时的MongoDB问题

[英]MongoDB issue at deployment

I am fairly new to MongoDB: my app running on my mac does not deploy well on ubuntu. 我对MongoDB相当陌生:我在Mac上运行的应用程序无法在ubuntu上很好地部署。

I have a very basic program that takes a JSon file and dumps it in a MongoDB db. 我有一个非常基本的程序,需要一个JSon文件并将其转储到MongoDB数据库中。 The MongoDB db is on a remote Ubuntu server called db . MongoDB数据库位于名为db的远程Ubuntu服务器上。

The program works fine on my Mac, in Eclipse and command line. 该程序可以在我的Mac,Eclipse和命令行上正常运行。

When I deploy it on my Ubuntu-based app server (different than the db server), I get: 在基于Ubuntu的应用服务器(不同于db服务器)上部署它时,我得到:

[cluster-ClusterId{value='572387cf96720e25144dce5b', description='null'}-db:27017] INFO org.mongodb.driver.cluster - Exception in monitor thread while connecting to server db:27017
com.mongodb.MongoInterruptedException: Interrupted acquiring a permit to retrieve an item from the pool

The app server can ping the db server. 应用服务器可以ping数据库服务器。

认为这是因为我的应用正在尝试将null对象另存为文档...

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM