我有一个带嵌入式jetty的应用程序网站(它是一个gradle应用程序),我正在使用gretty插件。 我需要快速重新加载所有'静态'应用程序资源,所以我在build.gradle中配置了gretty:
gretty {
serverConfigFile = file("$rootDir/jetty.xml")
contextConfigFile = file("$rootDir/src/main/webapp/WEB-INF/jetty-env.xml")
fastReload = "true"
}
问题在于,当我更改(例如).html文件时,执行守护程序开头的跟踪会出现在控制台中,但突然发生异常并且不会更改。
org.akhikhl.gretty.JettyScannerManager$1@3e199dce failed on '[/home/vjsantojaca/Developer/Relevante/relevanteme-web-2.0/src/main/webapp/templates/header.jsp]
java.net.ConnectException: Conexión rehusada
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:345)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at java.net.Socket.connect(Socket.java:538)
at java.net.Socket.<init>(Socket.java:434)
at java.net.Socket.<init>(Socket.java:244)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:408)
at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:77)
at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrapNoCoerce.callConstructor(ConstructorSite.java:102)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:194)
at org.akhikhl.gretty.ServiceProtocol.send(ServiceProtocol.groovy:42)
at org.akhikhl.gretty.ServiceProtocol$send$1.call(Unknown Source)
...
可能是什么原因?