环境: java21 问题: methods5不会输出log.info的内容, methods6正常打印log.info的内容 private static void methods5() { ThreadFactory tf = Thread.ofVirtual().factory(); try (ExecutorService executor = Executors.newVirtualThreadPerTaskExecutor()) { Thread vt = tf.newThread(() -> log.info("vt task executed.")); for (int i = 0; i log.info("thread task executed.")); for (int i = 0; i < 5; i++) { try { executor.submit(thread).get(); } catch (InterruptedException | ExecutionException e) { // 处理异常 } } } }