に達していない、私は2つのスレッド、TCP用とUDP第二のスレッドが
package com.main;
import com.utility.HibernateUtil;
public class ServerStarter {
public static void main(String[] args) {
System.out.print("Reach 1");
Thread tcp = new Thread(new TcpServerStarter());
tcp.start();
System.out.print("Reach 2");
Thread udp = new Thread(new UdpServerStarter());
System.out.print("Reach 3");
HibernateUtil.buildSessionFactory();
System.out.print("Reach 4");
}
public static class TcpServerStarter extends Thread{
public TcpServerStarter(){
new TcpServer(8500).run();
}
}
public static class UdpServerStarter extends Thread{
public UdpServerStarter(){
new UdpServer(1000).run();
}
}
}
のための1つを開始しようとしていますのみ「1に達する」と印字されています。私は、私は2つのコアを持っているが、私は単一のコアを持っている場合、これが発生する可能性があることを読んだ。
あなたはudpを開始していません! udp.start()を追加します。 –