+ changed Database Information to be configurable
+ added Prefix to MessageConstants
This commit is contained in:
parent
1badee9881
commit
499867b563
|
@ -10,7 +10,7 @@
|
||||||
</content>
|
</content>
|
||||||
<orderEntry type="inheritedJdk" />
|
<orderEntry type="inheritedJdk" />
|
||||||
<orderEntry type="sourceFolder" forTests="false" />
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
<orderEntry type="library" name="Maven: org.projectlombok:lombok:1.16.8" level="project" />
|
<orderEntry type="library" scope="PROVIDED" name="Maven: org.projectlombok:lombok:1.14.8" level="project" />
|
||||||
<orderEntry type="library" name="Maven: org.mongodb:mongo-java-driver:3.2.2" level="project" />
|
<orderEntry type="library" name="Maven: org.mongodb:mongo-java-driver:3.2.2" level="project" />
|
||||||
<orderEntry type="library" name="Maven: com.zaxxer:HikariCP:2.4.5" level="project" />
|
<orderEntry type="library" name="Maven: com.zaxxer:HikariCP:2.4.5" level="project" />
|
||||||
<orderEntry type="library" name="Maven: org.slf4j:slf4j-api:1.7.16" level="project" />
|
<orderEntry type="library" name="Maven: org.slf4j:slf4j-api:1.7.16" level="project" />
|
||||||
|
|
3
pom.xml
3
pom.xml
|
@ -84,7 +84,8 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.projectlombok</groupId>
|
<groupId>org.projectlombok</groupId>
|
||||||
<artifactId>lombok</artifactId>
|
<artifactId>lombok</artifactId>
|
||||||
<version>1.16.8</version>
|
<version>1.14.8</version>
|
||||||
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.mongodb</groupId>
|
<groupId>org.mongodb</groupId>
|
||||||
|
|
|
@ -23,16 +23,16 @@ public class DatabaseManager {
|
||||||
//TODO: remove hardcoded variables
|
//TODO: remove hardcoded variables
|
||||||
mongoDB = new MongoDB(config.getString("MongoDB.Host"), config.getInteger("MongoDB.Port"), config.getString("MongoDB.Username"), config.getString("MongoDB.Password"), config.getString("MongoDB.Database"));
|
mongoDB = new MongoDB(config.getString("MongoDB.Host"), config.getInteger("MongoDB.Port"), config.getString("MongoDB.Username"), config.getString("MongoDB.Password"), config.getString("MongoDB.Database"));
|
||||||
asyncMongoDB = new AsyncMongoDB(config.getString("MongoDB.Host"), config.getInteger("MongoDB.Port"), config.getString("MongoDB.Username"), config.getString("MongoDB.Password"), config.getString("MongoDB.Database"));
|
asyncMongoDB = new AsyncMongoDB(config.getString("MongoDB.Host"), config.getInteger("MongoDB.Port"), config.getString("MongoDB.Username"), config.getString("MongoDB.Password"), config.getString("MongoDB.Database"));
|
||||||
mySQL = new MySQL(config.getString("MySQL.Host"), config.getString("MySQL.Port"), config.getString("MySQL.Database"), config.getString("MySQL.Username"), config.getString("MySQL.Password"));
|
//mySQL = new MySQL(config.getString("MySQL.Host"), config.getString("MySQL.Port"), config.getString("MySQL.Database"), config.getString("MySQL.Username"), config.getString("MySQL.Password"));
|
||||||
asyncMySQL = new AsyncMySQL(config.getString("MySQL.Host"), config.getString("MySQL.Port"), config.getString("MySQL.Database"), config.getString("MySQL.Username"), config.getString("MySQL.Password"));
|
//asyncMySQL = new AsyncMySQL(config.getString("MySQL.Host"), config.getString("MySQL.Port"), config.getString("MySQL.Database"), config.getString("MySQL.Username"), config.getString("MySQL.Password"));
|
||||||
boardSQL = new AsyncMySQL(config.getString("BoardSQL.Host"), config.getString("BoardSQL.Port"), config.getString("BoardSQL.Database"), config.getString("BoardSQL.Username"), config.getString("BoardSQL.Password"));
|
//boardSQL = new AsyncMySQL(config.getString("BoardSQL.Host"), config.getString("BoardSQL.Port"), config.getString("BoardSQL.Database"), config.getString("BoardSQL.Username"), config.getString("BoardSQL.Password"));
|
||||||
}
|
}
|
||||||
|
|
||||||
public void closeConnections() {
|
public void closeConnections() {
|
||||||
mongoDB.closeConnection();
|
mongoDB.closeConnection();
|
||||||
asyncMongoDB.getMongoDB().closeConnection();
|
asyncMongoDB.getMongoDB().closeConnection();
|
||||||
mySQL.close();
|
//mySQL.close();
|
||||||
asyncMySQL.getMySQL().close();
|
//asyncMySQL.getMySQL().close();
|
||||||
boardSQL.getMySQL().close();
|
//boardSQL.getMySQL().close();
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -6,6 +6,8 @@ package eu.univento.commons.player.language;
|
||||||
*/
|
*/
|
||||||
public enum MessageConstant {
|
public enum MessageConstant {
|
||||||
|
|
||||||
|
PREFIX("Prefix"),
|
||||||
|
|
||||||
SYSTEM_UNKOWN_ERROR("System.unknown_error"),
|
SYSTEM_UNKOWN_ERROR("System.unknown_error"),
|
||||||
SYSTEM_CRITICAL_ERROR("System.critical_error"),
|
SYSTEM_CRITICAL_ERROR("System.critical_error"),
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,8 @@ public enum ServerType {
|
||||||
LOBBY(0, "Lobby", "§6Lobby"),
|
LOBBY(0, "Lobby", "§6Lobby"),
|
||||||
SECRET_GAME_FREE4ALL(1, "Free4All", "§6Free4All"),
|
SECRET_GAME_FREE4ALL(1, "Free4All", "§6Free4All"),
|
||||||
SECRET_GAME_TRASHGAMES(2, "TrashGames", "§6TrashGames"),
|
SECRET_GAME_TRASHGAMES(2, "TrashGames", "§6TrashGames"),
|
||||||
GAME_WOOLGET(3, "WoolGet", "§6WoolGet");
|
GAME_WOOLGET(3, "WoolGet", "§6WoolGet"),
|
||||||
|
GAME_MAYA(4, "Maya", "§6Maya");
|
||||||
|
|
||||||
private int id;
|
private int id;
|
||||||
private String name;
|
private String name;
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
MySQL.Host = univento.eu
|
MySQL.Host = vps.joethei.de
|
||||||
MySQL.Port = 3306
|
MySQL.Port = 3306
|
||||||
MySQL.Username = core
|
MySQL.Username = univento
|
||||||
MySQL.Database = core
|
MySQL.Database = univento
|
||||||
MySQL.Password = dWez!530Erwz7&44
|
MySQL.Password = dWez!530Erwz7&44
|
||||||
MongoDB.Host = univento.eu
|
MongoDB.Host = vps.joethei.de
|
||||||
MongoDB.Port = 27017
|
MongoDB.Port = 27017
|
||||||
MongoDB.Username = admin
|
MongoDB.Username = admin
|
||||||
MongoDB.Password = ++JT1415++
|
MongoDB.Password = ++JT1415++
|
||||||
MongoDB.Database = admin
|
MongoDB.Database = univento
|
||||||
BoardSQL.Host = univento.eu
|
BoardSQL.Host = univento.eu
|
||||||
BoardSQL.Port = 3306
|
BoardSQL.Port = 3306
|
||||||
BoardSQL.Username = forum
|
BoardSQL.Username = forum
|
||||||
|
|
Loading…
Reference in New Issue