首页 > 代码库 > spring-mongodb can't call something : /172.16.9.54:27017/mo;

spring-mongodb can't call something : /172.16.9.54:27017/mo;

解决办法:设置SocketTimeout

spring配置如下:

  <mongo:options connections-per-host="500" socket-timeout="5000" max-wait-time="5000"                       threads-allowed-to-block-for-connection-multiplier="1000"                       connect-timeout="30000"/>

spring-mongodb can't call something : /172.16.9.54:27017/mo;