Jetty with Intellij on Windows

I recently started seeing this error on startup on Windows. It looks like Jetty is choking when trying to parse a windows file URI representation of the working directory while trying to locate the WEB-INF folder. Has anyone run into this problem? Is there a workaround?

15:38:24 WARN [webapp.WebAppContext] - Failed startup of context oeje10w.WebAppContext@6b739528{/geoserver,/geoserver,b=file:///C:/Users/jmiller/code/geoserver/src/web/app/src/main/webapp/,a=STOPPED,h=oeje10s.SessionHandler@622ef26a{STOPPED}}{src/main/webapp}
java.nio.file.InvalidPathException: Illegal char <:> at index 2: /C:/Users/jmiller/code/geoserver/src/web/app/src/main/webapp/WEB-INF/
at java.base/sun.nio.fs.WindowsPathParser.normalize(WindowsPathParser.java:204)
at java.base/sun.nio.fs.WindowsPathParser.parse(WindowsPathParser.java:175)
at java.base/sun.nio.fs.WindowsPathParser.parse(WindowsPathParser.java:77)
at java.base/sun.nio.fs.WindowsPath.parse(WindowsPath.java:92)
at java.base/sun.nio.fs.WindowsFileSystem.getPath(WindowsFileSystem.java:231)
at java.base/java.nio.file.Path.resolve(Path.java:516)
at org.eclipse.jetty.util.resource.PathResource.resolveSchemeSpecificPath(PathResource.java:315)
at org.eclipse.jetty.util.resource.PathResource.resolve(PathResource.java:296)
at org.eclipse.jetty.ee10.webapp.WebAppContext.getWebInf(WebAppContext.java:866)
at org.eclipse.jetty.ee10.webapp.WebXmlConfiguration.findWebXml(WebXmlConfiguration.java:112)
at org.eclipse.jetty.ee10.webapp.WebXmlConfiguration.preConfigure(WebXmlConfiguration.java:71)
at org.eclipse.jetty.ee10.webapp.Configurations.preConfigure(Configurations.java:489)
at org.eclipse.jetty.ee10.webapp.WebAppContext.preConfigure(WebAppContext.java:479)
at org.eclipse.jetty.ee10.webapp.WebAppContext.doStart(WebAppContext.java:522)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:92)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:170)
at org.eclipse.jetty.server.Server.start(Server.java:689)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:121)
at org.eclipse.jetty.server.Handler$Abstract.doStart(Handler.java:545)
at org.eclipse.jetty.server.Server.doStart(Server.java:630)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:92)
at org.geoserver.web.Start.main(Start.java:120)

This has not been mentioned yet, can I ask what Java and version of GeoServer you are seeing this in?

Right now I cannot tell if recently means:

  • updated geoserver so new version of jetty
  • updated geoserver so something with URL handling changed
  • udpated java so something with URL handling changed

The stack trace indicates /C:/Users/jmiller/code/geoserver/src/web/app/src/main/webapp/WEB-INF/ is the problem, I assume the leading / needs to be removed?