diff --git a/LaunchServer/src/main/java/ru/gravit/launchserver/websocket/WebSocketService.java b/LaunchServer/src/main/java/ru/gravit/launchserver/websocket/WebSocketService.java index 915fc9f3..e6aad83a 100644 --- a/LaunchServer/src/main/java/ru/gravit/launchserver/websocket/WebSocketService.java +++ b/LaunchServer/src/main/java/ru/gravit/launchserver/websocket/WebSocketService.java @@ -16,7 +16,6 @@ import ru.gravit.launcher.request.ResultInterface; import ru.gravit.launchserver.LaunchServer; import ru.gravit.launchserver.socket.Client; -import ru.gravit.launchserver.websocket.json.EchoResponse; import ru.gravit.launchserver.websocket.json.JsonResponseAdapter; import ru.gravit.launchserver.websocket.json.JsonResponseInterface; import ru.gravit.launchserver.websocket.json.SimpleResponse; @@ -99,7 +98,6 @@ public void registerClient(Channel channel) { } public void registerResponses() { - registerResponse("echo", EchoResponse.class); registerResponse("auth", AuthResponse.class); registerResponse("checkServer", CheckServerResponse.class); registerResponse("joinServer", JoinServerResponse.class); diff --git a/LaunchServer/src/main/java/ru/gravit/launchserver/websocket/json/EchoResponse.java b/LaunchServer/src/main/java/ru/gravit/launchserver/websocket/json/EchoResponse.java deleted file mode 100644 index 257af457..00000000 --- a/LaunchServer/src/main/java/ru/gravit/launchserver/websocket/json/EchoResponse.java +++ /dev/null @@ -1,25 +0,0 @@ -package ru.gravit.launchserver.websocket.json; - -import io.netty.channel.ChannelHandlerContext; -import ru.gravit.launcher.events.request.EchoRequestEvent; -import ru.gravit.launchserver.socket.Client; -import ru.gravit.utils.helper.LogHelper; - -public class EchoResponse extends SimpleResponse { - public final String echo; - - public EchoResponse(String echo) { - this.echo = echo; - } - - @Override - public String getType() { - return "echo"; - } - - @Override - public void execute(ChannelHandlerContext ctx, Client client) { - LogHelper.info("Echo: %s, isAuth %s", echo, client.isAuth ? "true" : "false"); - service.sendObject(ctx, new EchoRequestEvent(echo)); - } -} diff --git a/LauncherAPI/src/main/java/ru/gravit/launcher/request/websockets/ClientWebSocketService.java b/LauncherAPI/src/main/java/ru/gravit/launcher/request/websockets/ClientWebSocketService.java index b47ccf66..3731eb51 100644 --- a/LauncherAPI/src/main/java/ru/gravit/launcher/request/websockets/ClientWebSocketService.java +++ b/LauncherAPI/src/main/java/ru/gravit/launcher/request/websockets/ClientWebSocketService.java @@ -102,7 +102,6 @@ public void registerResult(String key, Class clazz) { } public void registerResults() { - registerResult("echo", EchoRequestEvent.class); registerResult("auth", AuthRequestEvent.class); registerResult("checkServer", CheckServerRequestEvent.class); registerResult("joinServer", JoinServerRequestEvent.class); diff --git a/libLauncher/src/main/java/ru/gravit/launcher/events/request/EchoRequestEvent.java b/libLauncher/src/main/java/ru/gravit/launcher/events/request/EchoRequestEvent.java deleted file mode 100644 index 6d57bb04..00000000 --- a/libLauncher/src/main/java/ru/gravit/launcher/events/request/EchoRequestEvent.java +++ /dev/null @@ -1,27 +0,0 @@ -package ru.gravit.launcher.events.request; - -import ru.gravit.launcher.LauncherNetworkAPI; -import ru.gravit.launcher.events.RequestEvent; -import ru.gravit.utils.event.EventInterface; - -import java.util.UUID; - -public class EchoRequestEvent extends RequestEvent implements EventInterface { - private static final UUID uuid = UUID.fromString("0a1f820f-7cd5-47a5-ae0e-17492e0e1fe1"); - @LauncherNetworkAPI - public String echo; - - public EchoRequestEvent(String echo) { - this.echo = echo; - } - - @Override - public String getType() { - return "echo"; - } - - @Override - public UUID getUUID() { - return uuid; - } -}