Jetty startup problem: WebAppContext: Failed to start context oejwWebAppContext {/, null}

I am trying to start a new project war with maven and spring in the spring Tool Suite IDE, I downloaded the project from the Git Hub, the project was done on macs, and I work in windows.

This is what I get when I try to start the Jetty server:

2013-09-03 10:01:47.161:INFO:oejs.Server:jetty-8.1.12.v20130726 2013-09-03 10:01:47.179:INFO:oejdp.ScanningAppProvider:Deployment monitor C:\Users\HP\Documents\workspace-sts-3.3.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\webapps at interval 1 2013-09-03 10:01:47.183:INFO:oejdp.ScanningAppProvider:Deployment monitor C:\Users\HP\Documents\workspace-sts-3.3.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\contexts at interval 1 2013-09-03 10:01:47.187:INFO:oejd.DeploymentManager:Deployable added: C:\Users\HP\Documents\workspace-sts-3.3.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\contexts\moca-console.xml 2013-09-03 10:01:47.238:WARN:oejw.WebInfConfiguration:Web application not found C:\Users\HP\Documents\workspace-sts-3.3.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp0/wtpwebapps/moca-console 2013-09-03 10:01:47.239:WARN:oejw.WebAppContext:Failed startup of context oejwWebAppContext{/,null},C:\Users\HP\Documents\workspace-sts-3.3.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp0/wtpwebapps/moca-console java.io.FileNotFoundException: C:\Users\HP\Documents\workspace-sts-3.3.0.RELEASE\.metadata\.plugins\org.eclipse.wst.server.core\tmp0/wtpwebapps/moca-console at org.eclipse.jetty.webapp.WebInfConfiguration.unpack(WebInfConfiguration.java:502) at org.eclipse.jetty.webapp.WebInfConfiguration.preConfigure(WebInfConfiguration.java:71) at org.eclipse.jetty.webapp.WebAppContext.preConfigure(WebAppContext.java:457) at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:493) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) at org.eclipse.jetty.deploy.bindings.StandardStarter.processBinding(StandardStarter.java:39) at org.eclipse.jetty.deploy.AppLifeCycle.runBindings(AppLifeCycle.java:186) at org.eclipse.jetty.deploy.DeploymentManager.requestAppGoal(DeploymentManager.java:494) at org.eclipse.jetty.deploy.DeploymentManager.addApp(DeploymentManager.java:141) at org.eclipse.jetty.deploy.providers.ScanningAppProvider.fileAdded(ScanningAppProvider.java:145) at org.eclipse.jetty.deploy.providers.ScanningAppProvider$1.fileAdded(ScanningAppProvider.java:56) at org.eclipse.jetty.util.Scanner.reportAddition(Scanner.java:615) at org.eclipse.jetty.util.Scanner.reportDifferences(Scanner.java:540) at org.eclipse.jetty.util.Scanner.scan(Scanner.java:403) at org.eclipse.jetty.util.Scanner.doStart(Scanner.java:337) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) at org.eclipse.jetty.deploy.providers.ScanningAppProvider.doStart(ScanningAppProvider.java:121) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) at org.eclipse.jetty.deploy.DeploymentManager.startAppProvider(DeploymentManager.java:555) at org.eclipse.jetty.deploy.DeploymentManager.doStart(DeploymentManager.java:230) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) at org.eclipse.jetty.util.component.AggregateLifeCycle.doStart(AggregateLifeCycle.java:81) at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:58) at org.eclipse.jetty.server.handler.HandlerWrapper.doStart(HandlerWrapper.java:96) at org.eclipse.jetty.server.Server.doStart(Server.java:282) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:64) at org.eclipse.jetty.xml.XmlConfiguration$1.run(XmlConfiguration.java:1259) at java.security.AccessController.doPrivileged(Native Method) at org.eclipse.jetty.xml.XmlConfiguration.main(XmlConfiguration.java:1182) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:601) at org.eclipse.jetty.start.Main.invokeMain(Main.java:473) at org.eclipse.jetty.start.Main.start(Main.java:615) at org.eclipse.jetty.start.Main.main(Main.java:96) 2013-09-03 10:01:47.277:INFO:oejs.AbstractConnector:Started SelectChannelConnector@0.0.0.0:8080 

I tried a bunch of possible solutions without success. Any suggestion would be welcome.

+8
spring eclipse maven jetty
source share
2 answers

It seems that your Eclipse STS workspace is not in sync with the content published on the server. Try cleaning the server, cleaning the working directory, cleaning all projects, and republishing the project to the server.

If this does not work, try these steps to restore the eclipse workspace:

  • close eclipse and do a clean maven installation from the command line
  • delete all eclipse-related files: .project, .classpath and .settings
  • plug eclipse again and configure maven to use the same maven as on the command line
  • import a project using Import as a Maven Project
  • dispose of your Jetty and reload a clean file
  • Create a new Jetty server, point it to the new Jetty and add your application to it.
  • Re-run the application and start the server
+3
source share

Yes, this seems like a problem with plugins. So just close the STS. Removing a workspace or plugin is not a good idea. This can create a problem for other projects.

And follow these steps -

  • right-click on the project in the project explorer.
  • select the maven-> update-> tick all enable checkbox, then click ok
  • This will update the entire plugin creating the problem.

Best of luck

+1
source share

All Articles