Package com.mongodb

Examples of com.mongodb.DBAddress


        }

        // need to append db to url.
        url += "/" + dbname;

        Mongo mongo = new Mongo(new DBAddress(url));

        DB db = mongo.getDB(dbname);
        db.dropDatabase();
        mongo.close();
    }
View Full Code Here


            // http://www.mongodb.org/display/DOCS/Connections
            if (url.startsWith("mongodb://")) {
                url = url.substring(10);
            }

            mongo = new Mongo(new DBAddress(url));
        } catch (Exception e1) {
            logger.error(
                    "Could not initialize MongoDB connection pool for Loader: "
                            + e1, e1);
            return;
View Full Code Here

TOP

Related Classes of com.mongodb.DBAddress

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.