idea下开启undertow开发模式热加载一编译就报错程序死掉


Loading changes ......

2019-02-21 10:51:33:398 INFO [com.alibaba.druid.pool.DruidDataSource] {dataSource-1} closed

Exception in thread "HotSwapWatcher" java.lang.NoClassDefFoundError: com/axinfu/tyfp/controller/IndexController

at com.axinfu.tyfp.AdminRoutes.config(AdminRoutes.java:15)

at com.jfinal.config.Routes.add(Routes.java:68)

at com.axinfu.tyfp.AppConfig.configRoute(AppConfig.java:43)

at com.jfinal.core.Config.configJFinal(Config.java:54)

at com.jfinal.core.JFinal.init(JFinal.java:61)

at com.jfinal.core.JFinalFilter.init(JFinalFilter.java:63)

at io.undertow.servlet.core.LifecyleInterceptorInvocation.proceed(LifecyleInterceptorInvocation.java:111)

at io.undertow.servlet.core.ManagedFilter.createFilter(ManagedFilter.java:80)

at io.undertow.servlet.core.DeploymentManagerImpl$2.call(DeploymentManagerImpl.java:589)

at io.undertow.servlet.core.DeploymentManagerImpl$2.call(DeploymentManagerImpl.java:554)

at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:42)

at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43)

at io.undertow.servlet.core.DeploymentManagerImpl.start(DeploymentManagerImpl.java:596)

at com.jfinal.server.undertow.UndertowServer.configHttp(UndertowServer.java:277)

at com.jfinal.server.undertow.UndertowServer.doStart(UndertowServer.java:255)

at com.jfinal.server.undertow.UndertowServer.restart(UndertowServer.java:409)

at com.jfinal.server.undertow.hotswap.HotSwapWatcher.doRun(HotSwapWatcher.java:133)

at com.jfinal.server.undertow.hotswap.HotSwapWatcher.run(HotSwapWatcher.java:91)

Caused by: java.lang.ClassNotFoundException: com.axinfu.tyfp.controller.IndexController

at java.net.URLClassLoader.findClass(URLClassLoader.java:382)

at java.lang.ClassLoader.loadClass(ClassLoader.java:424)

at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349)

at java.lang.ClassLoader.loadClass(ClassLoader.java:357)

at com.jfinal.server.undertow.hotswap.HotSwapClassLoader.loadClass(HotSwapClassLoader.java:106)

at java.lang.ClassLoader.loadClass(ClassLoader.java:357)

... 18 more

Disconnected from the target VM, address: '127.0.0.1:4468', transport: 'socket'


Process finished with exit code 0


评论区

jounzhang

2019-02-21 10:53

cnzzr

2019-02-21 14:12

升级 IDEA 2018.3 或者使用 Eclipse

热门反馈

扫码入社