On windows system, Jetty will lock deployed files by default at runtime.
You can find the jetty jar package in the local maven warehouse and change the webdefault.xml in it;
Or copy webdefault.xml, after pom.xml configuration, later Jetty restarting webdefault.xml will overwrite the settings of jetty.
1. Copy webdefault.xml to the src\main of the project \resources directory (customizable)
2. Modify webdefault.xml, the initialization configuration parameter useFileMappedBuffer of the locked file is false (default is true)
< pre class="prettyprint">
3. Modify the pom.xml configuration file
<webDefaultXml>${basedir}/src/main/resources/webdefault.xmlwebDefaultXml>
4. Reminder: The startup of jetty on my machine is jetty:run; if it is jetty:run-war, the above commands do not work of.
5. Warm reminder: Chrome Browser clears page js file cache
F12 calls out developer mode
Click Network, check Disable cache
F5 or right click to refresh
p>
On the windows system, jetty will lock the deployed files by default at runtime The deployed file.
You can find the jetty jar package in the local maven warehouse and change the webdefault.xml in it;
Or copy webdefault.xml, after pom.xml configuration, later Jetty restarting webdefault.xml will overwrite the settings of jetty.
1. Copy webdefault.xml to the src\main of the project \resources directory (customizable)
2. Modify the initialization configuration parameter useFileMappedBuffer of the locked file in webdefault.xml to false (default is true)
< pre class="prettyprint">
3. Modify pom.xml configuration file
<webDefaultXml>${basedir}/src/main/resources/webdefault.xmlwebDefaultXml< /span>>
4. Warm reminder: Jetty:run is started on my machine; if it is jetty:run-war, the above command does not work.
5. Warm reminder: Chrome Browser clears page js file cache
F12 calls out developer mode
Click Network, check Disable cache
F5 or right click to refresh
p>