升到jdk21出现的问题,需要增加虚拟机参数
--add-opens java.base/sun.nio.ch=ALL-UNNAMED顺带说一句,在IDEA项目的设置里面,Add VM options里面增加