Beispiel #1
0
    def set_up(self, settings, storage_name):

        BaseNosqlSession.set_up(self, settings, storage_name)
        server = couchdb.Server(self.db_host)

        try:
            self.db = server[settings.COUCH_DB_NAME]
        except:
            self.db = server.create(settings.COUCH_DB_NAME)
Beispiel #2
0
    def set_up(self, settings, storage_name):

        BaseNosqlSession.set_up(self, settings, storage_name)
        server = couchdb.Server(self.db_host)

        try:
            self.db = server[settings.COUCH_DB_NAME]
        except:
            self.db = server.create(settings.COUCH_DB_NAME)
Beispiel #3
0
    def set_up(self, settings, storage_name):

        BaseNosqlSession.set_up(self, settings, storage_name)

        self.connection = MongoClient(self.db_host)
        self.db = getattr(self.connection, self.settings.MONGO_DB_NAME)
Beispiel #4
0
    def set_up(self, settings, storage_name):

        BaseNosqlSession.set_up(self, settings, storage_name)

        self.connection = MongoClient(self.db_host)
        self.db = getattr(self.connection, self.settings.MONGO_DB_NAME)