Change certs dir location
This commit is contained in:
@@ -7,6 +7,7 @@ import java.net.Socket;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
|
||||
public class SocketManager {
|
||||
|
||||
public static void send(Socket socket, String data) throws IOException {
|
||||
OutputStream output = socket.getOutputStream();
|
||||
output.write(String.format("%s\r\n", data).getBytes(StandardCharsets.UTF_8));
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
package externalApp.externalApp.src;
|
||||
|
||||
import common.common.src.logger.Logger;
|
||||
|
||||
public class Main {
|
||||
public static void main(String[] args) {
|
||||
|
||||
Logger.displayInfo("Hello World");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,9 +1,19 @@
|
||||
package httpsServer.httpServer.src;
|
||||
import common.common.src.logger.Logger;
|
||||
|
||||
import common.common.src.socket.SocketManager;
|
||||
|
||||
import java.net.InetSocketAddress;
|
||||
import java.net.Socket;
|
||||
|
||||
public class Main {
|
||||
public static void main(String[] args) {
|
||||
System.out.println("Hello World!");
|
||||
Logger.displayInfo("Hello World!");
|
||||
|
||||
final InetSocketAddress address = new InetSocketAddress("127.0.0.1", 8043);
|
||||
|
||||
try(Socket socket = new Socket()){
|
||||
socket.bind(address);
|
||||
} catch (Exception e){
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user