reverb / wordnik-oss

Wordnik Open Source Software
168 stars 39 forks source link

Exception while trying to use SnapshotUtil for a MongoLab instance #30

Open carlphilipp opened 9 years ago

carlphilipp commented 9 years ago

Hi,

Thank you for this awesome tool! I have an issue when trying to use SnapshotUtil for a MongoLab database instance (https://mongolab.com/). I'm not sure exactly what's wrong, but here is the exception:

ERROR StatusLogger No log4j2 configuration file found. Using default configuration: logging only errors to the console. Jun 25, 2015 10:00:29 PM com.wordnik.mongo.connection.MongoDBConnectionManager$ getConnection SEVERE: can't get connection to dsXXXXXX.mongolab.com:31XXX/XXXXX with username Some(XXXXX), password XXXXXXXXX Exception in thread "main" java.lang.RuntimeException: com.wordnik.mongo.connection.PersistenceException at com.wordnik.system.mongodb.SnapshotUtil.getCollections(SnapshotUtil.java:161) at com.wordnik.system.mongodb.SnapshotUtil.run(SnapshotUtil.java:70) at com.wordnik.system.mongodb.SnapshotUtil.main(SnapshotUtil.java:65) at com.epickur.api.dump.MongoDBDump.exportMongo(MongoDBDump.java:114) at com.epickur.api.cron.MongoDBDumpJob.execute(MongoDBDumpJob.java:26) at com.epickur.api.cron.MongoDBDumpJob.main(MongoDBDumpJob.java:44) Caused by: com.wordnik.mongo.connection.PersistenceException at com.wordnik.mongo.connection.MongoDBConnectionManager$.getConnection(MongoDBConnectionManager.scala:147) at com.wordnik.mongo.connection.MongoDBConnectionManager$.getConnection(MongoDBConnectionManager.scala:93) at com.wordnik.mongo.connection.MongoDBConnectionManager.getConnection(MongoDBConnectionManager.scala) at com.wordnik.system.mongodb.SnapshotUtil.getCollections(SnapshotUtil.java:118) ... 5 more

Any suggestions? Regards, Carl

fehguy commented 9 years ago

Hi Carl, can you share the command-line that you're using? Feel free to remove anything private.

carlphilipp commented 9 years ago

-d DATABASE -o C:\tmp -u USER -p PASSWORD -h dsXXXXXX.mongolab.com:PORT

The directory on my local computer exists. On a side note, I'm calling the static method from my code and I use Maven