Compare commits

...

2 Commits

Author SHA1 Message Date
alex c31641701d test 2022-04-09 22:09:41 +02:00
Alex 7d85f98384 redis added to the config handler 2022-04-06 21:28:06 +02:00
30 changed files with 6 additions and 19 deletions

0
pom.xml Normal file → Executable file
View File

0
src/main/java/net/krakatoa/proxy/ProxySystem.java Normal file → Executable file
View File

View File

View File

View File

View File

@ -25,6 +25,9 @@ public class ConfigHandler {
private String mongodbUsername; private String mongodbUsername;
private String mongodbPassword; private String mongodbPassword;
private String redisHost;
private String redisPort;
public void load() throws IOException { public void load() throws IOException {
Configuration configuration = ConfigurationProvider.getProvider(YamlConfiguration.class) Configuration configuration = ConfigurationProvider.getProvider(YamlConfiguration.class)
.load(new File("/home/kra-minecraft/kraConfigs", "kraSettings.yaml")); .load(new File("/home/kra-minecraft/kraConfigs", "kraSettings.yaml"));
@ -42,5 +45,8 @@ public class ConfigHandler {
mongodbDatabase = configuration.getString("mongodb.database"); mongodbDatabase = configuration.getString("mongodb.database");
mongodbUsername = configuration.getString("mongodb.username"); mongodbUsername = configuration.getString("mongodb.username");
mongodbPassword = configuration.getString("mongodb.password"); mongodbPassword = configuration.getString("mongodb.password");
redisHost = configuration.getString("redis.host");
redisPort = configuration.getString("redis.port");
} }
} }

View File

View File

@ -65,25 +65,6 @@ public class PlayerDisconnectListener implements Listener {
if (!map.isEmpty()) { if (!map.isEmpty()) {
map.delete(); map.delete();
} }
/*Long res = ProxySystem.getInstance().getRedisManager().getRedisKeyCommands()
.del("player:" + proxiedPlayer.getUniqueId().toString());
ProxySystem.getInstance().getLogger().info("val: " + res);
//String uuid = ProxySystem.getInstance().getFormatter()
// .formatUuid(proxiedPlayer.getUniqueId().toString());
/*
ProxySystem.getInstance().getPlayerRegistrationProcess()
.deleteOne(Filters.eq("uuid", uuid),
(deleteResult, throwable) -> {
System.out.println("delete " + deleteResult.getDeletedCount());
}); */
} }
} }

View File

View File

0
src/main/java/net/krakatoa/proxy/redis/PlayerTest.java Normal file → Executable file
View File

View File

0
src/main/java/net/krakatoa/proxy/util/Formatter.java Normal file → Executable file
View File

0
src/main/resources/plugin.yml Normal file → Executable file
View File

0
target/classes/net/krakatoa/proxy/ProxySystem.class Normal file → Executable file
View File

View File

View File

View File

View File

View File

View File

View File

0
target/classes/net/krakatoa/proxy/util/Formatter.class Normal file → Executable file
View File

0
target/classes/plugin.yml Normal file → Executable file
View File

0
target/maven-archiver/pom.properties Normal file → Executable file
View File