public static void main()

in log4j-server/src/main/java/org/apache/logging/log4j/server/UdpSocketServer.java [76:91]


    public static void main(final String[] args) throws Exception {
        final CommandLineArguments cla = CommandLine.populateCommand(new CommandLineArguments(), args);
        if (cla.isHelp() || cla.getPort() < 0) {
            CommandLine.usage(cla, System.err);
            return;
        }
        if (cla.getConfigLocation() != null) {
            ConfigurationFactory.setConfigurationFactory(new ServerConfigurationFactory(cla.getConfigLocation()));
        }
        final UdpSocketServer<InputStream> socketServer = UdpSocketServer
                .createJsonSocketServer(cla.getPort());
        final Thread serverThread = socketServer.startNewThread();
        if (cla.isInteractive()) {
            socketServer.awaitTermination(serverThread);
        }
    }