예제 #1
0
    def __init__(self):
        DatabasePlugin.__init__(self)

        # noinspection PyUnresolvedReferences
        dbpassword = config.get("database", "password")
        if dbpassword:
            dbpool = MyConnectionPool(config.get("database", "adapter"),
                                      user=config.get("database", "username"),
                                      password=dbpassword,
                                      host=config.get("database", "host"),
                                      port=config.get("database", "port"),
                                      database=config.get("database", "dbname"))
        else:
            dbpool = MyConnectionPool(config.get("database", "adapter"),
                                      user=config.get("database", "username"),
                                      database=config.get("database", "dbname"))
        self.dbpool = dbpool
예제 #2
0
    def __init__(self):
        DatabasePlugin.__init__(self)

        # noinspection PyUnresolvedReferences
        dbpassword = config.get("database", "password")
        if dbpassword:
            dbpool = MyConnectionPool(config.get("database", "adapter"),
                                      user=config.get("database", "username"),
                                      password=dbpassword,
                                      host=config.get("database", "host"),
                                      port=config.get("database", "port"),
                                      database=config.get(
                                          "database", "dbname"))
        else:
            dbpool = MyConnectionPool(config.get("database", "adapter"),
                                      user=config.get("database", "username"),
                                      database=config.get(
                                          "database", "dbname"))
        self.dbpool = dbpool
예제 #3
0
파일: mem.py 프로젝트: ysobolev/sputnik
 def __init__(self):
     DatabasePlugin.__init__(self)
     self.users = {}
예제 #4
0
파일: mem.py 프로젝트: Mrkebubun/sputnik
 def __init__(self):
     DatabasePlugin.__init__(self)
     self.users = {}