29

I'm developing web application. Everything was working fine till yesterday.

Something happened yesterday (no idea what exactly) and Eclipse is not deploying my application any more.

I'm using spring and maven, but it worked before, so I think there is no problem in this.

When I'm starting my application there is this in startup log:

7.9.2012 12:39:23 org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Java\jdk1.6.0_31\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:/Program Files (x86)/Java/jre6/bin/client;C:/Program Files (x86)/Java/jre6/bin;C:/Program Files (x86)/Java/jre6/lib/i386;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files (x86)\CVSNT\;c:\Programs\apache-ant-1.8.1\bin;C:\Program Files (x86)\Common Files\Teleca Shared;C:\SSD\Oracle11g\product\11.2.0\dbhome_3\bin;C:\SSD\Oracle11g\product\11.2.0\dbhome_1\bin;C:\Program Files (x86)\Groovy\Groovy-1.8.6\bin;C:\Programs\TortoiseSVN-1.7.7\bin;c:\Programs\apache-ant-1.8.1\bin;c:\Program Files\Java\jdk1.6.0_31\bin;c:\Programs\cygwin\bin;c:\Programs\apache-maven-2.2.1\bin;C:\SSD\Mudrc\Eclipse;;.
7.9.2012 12:39:23 org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:MudrcWeb2' did not find a matching property.
7.9.2012 12:39:23 org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-9091"]
7.9.2012 12:39:23 org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
7.9.2012 12:39:23 org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 491 ms
7.9.2012 12:39:23 org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
7.9.2012 12:39:23 org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.29
7.9.2012 12:39:24 org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-9091"]
7.9.2012 12:39:24 org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-bio-8009"]
7.9.2012 12:39:24 org.apache.catalina.startup.Catalina start
INFO: Server startup in 693 ms

While I'm using spring, there should be at least context initialization in log.

I read several similar questions here

but nothing helped

I tried adding new server to Eclipse, renaming project, cleaning and still it is the same.

When I build it with maven I can deploy it to Tomcat and it works.

Community
  • 1
  • 1
Betlista
  • 10,327
  • 13
  • 69
  • 110
  • Actually it was your link to the similar question "Tomcat started in eclipse but unable to connect to link to http://localhost:8085/" that resolved the problem for me. Thanks for posting your research links! – mojoken May 18 '16 at 18:19
  • 4
    I think the real issue is that there are no messages to explain what is wrong in the eclipse/tomcat integration, It's always a roll of the dice. – pojo-guy Oct 03 '18 at 15:08

17 Answers17

26

Have you check your deploy path in Server Locations? May be your tomcat deploy path changed and Eclipse is not deploying your application.

In eclipse.

  1. Window -> Show View -> Servers.
  2. Double click to your server.
  3. In Tomcat Server's Overview.

    3.1 check your Server Path

    3.2 check your Deploy Path

swemon
  • 5,840
  • 4
  • 32
  • 54
  • 16
    That really helped, I realized that there are not all files I would expect. What solved my problem was to make `right click on project > Maven > Update Project Configuration`. – Betlista Sep 07 '12 at 11:00
  • 1
    Today I'm using `mvn eclipse:eclipse` to generate .project and .classpath files. – Betlista Jan 11 '13 at 16:54
  • Sometime **.project** file may not have sufficient entries under **** tag. Yes, right click on project > Maven > Update Project Configuration worked for me as suggested by @Betlista. – Paramesh Korrakuti Feb 05 '16 at 13:07
  • 1
    For me the more specific fix was to replace the default Eclipse (Mars Release 2) Deploy path with the `webapps` subdirectory of my Tomcat installation. – Mark A. Fitzgerald May 02 '16 at 04:13
11

Maybe the deploy Maven assembly in project properties is missing:

enter image description here

Tobia
  • 9,165
  • 28
  • 114
  • 219
  • Do not do this! Read the second comment. https://bugs.eclipse.org/bugs/show_bug.cgi?id=430465 – T3rm1 May 25 '18 at 14:01
  • This was the only solution for me, i tried all others. I can accept an overhead of libraries in developement enviroment – Tobia May 25 '18 at 15:39
6

I have this similar problem where I'm able to start the tomcat server but however application not initialized or started, so I have Right clicked on my project --> Deployment Assembly --> Click 'Add' in the right side panel, select 'Java Build path entries' and click 'Next', Now select 'Maven dependencies' and click 'Finish'. Now I run the server and it started the application successfully.

enter image description here enter image description here
enter image description here

Suresh
  • 1,491
  • 2
  • 22
  • 27
5

SOLVED: I faced this error and i cant understand, it took 5 hours.

Solution: project properties/Project faced/Dynamic web-module version set to 3.0

after one week ,I got same error

FIXED2 gwt-project-external-mode-main-main-nocache-js-not-found

Community
  • 1
  • 1
robert lennon
  • 194
  • 1
  • 3
  • 10
4

I have faced this issue and I just removed the server from eclipse and re-configured it... And everything started working fine... I have faced it two three times and the same thing worked.

Anuj Sharma
  • 111
  • 1
  • 1
  • 9
2

Same problem, not sure why it occurred only after upgrading from Spring v3.2.x to v4.2.x.

Solved it by doing the following:

  1. Clear all eclipse files [.classpath, .project, .settings/].
  2. Perform >mvn eclipse:eclipse
  3. Perform eclipse>project>properties>deployment assembly add [referenced projects, additional classpaths].

Publish and Start the module in Tomcat tab, it now starts properly.

JayabalanAaron
  • 360
  • 3
  • 13
2

Drop server.......... Window -> Show View -> Servers. Click right - > Delete

Click right in the Project Run Configuration

and add Server again......

1

I had the same problem. I fixed it by makinbg the following entry in org.eclipse.wst.common.project.facet.core.xml

<runtime name="Apache Tomcat v7.0" />

Now this complete file looks like -

<?xml version="1.0" encoding="UTF-8"?>
<faceted-project>
    <runtime name="Apache Tomcat v7.0" />
    <fixed facet="wst.jsdt.web" />
    <installed facet="java" version="1.5" />
    <installed facet="jst.web" version="2.3" />
    <installed facet="wst.jsdt.web" version="1.0" />
</faceted-project>
Popeye
  • 1,548
  • 3
  • 25
  • 39
  • your solution work with me ... but it work for ever ? – sam Oct 11 '16 at 15:57
  • Sorry bro.. It was long time ago and I don't even remember why or how it happened.. But in general, I think it should work for ever... – Popeye Oct 12 '16 at 13:10
0

look into org.eclipse.wst.common.component file in your web project in eclipse.

< wb-module deploy-name="PROJECT_NAME">

check the PROJECT_NAME. It might got messed up. Similarly look into .project file.

Hope this helps!!

user1198477
  • 53
  • 1
  • 6
0

I encountered with same error and resolved it with redeployment after removing deployment.

aneela
  • 1,457
  • 3
  • 24
  • 45
0

The only way I found which works for me is adding an entry into the "Web Deployment Assembly"

Project webapp > Properties > Deployment Assembly
Add ...
Source : "/target/classes"
Deploy Path : "WEB-INF/classes"

willome
  • 3,062
  • 19
  • 32
0

I fixed this issue, this way:

  1. Stop the Server
  2. Remove the previous Deploy that You did
  3. Clean it
  4. Deploy it again
Archmede
  • 1,592
  • 2
  • 20
  • 37
Carlos
  • 1
0

Depsite the year old topic, this one seems to have the most of the answers for this problem. Just ren into it. Tried everything, starting from "cleans", ending with total ".metadata" and another server setup, and nothing worked.

Than i remembered that a while ago i'w decided to clean up some of the "pom" warnings, and there were some suggestions on "apply to the project data". Then i started to browse the folder project, where i found the source of my headache - a file called ".tomcatplugin". After deleting it(it was the third hour of my attempts of resolving the problem) everything worked like a charm.

Draaksward
  • 759
  • 7
  • 32
0

Got it :)

Usually caused when eclipse is reffering to another (or in correct web folder, may be webConent)

  1. Update .settings/.jsdtscope to have correct entry for webapp, similar to below

  1. Update org.eclipse.wst.common.component to have correct entry for webapp

0

I have the same problem, my solution is:

  • Install WTP Maven integration (don't know if this is necessary)
  • Project -> Run Configurations (Select your tomcat server) -> Run

For a few hours I tried to deploy and start application using Servers window but it didn't worked. My war was not placed in wptwebapps folder, manually deplying war to webapps worked.

Using Run Configurations made my app finally deployable...

csharpfolk
  • 4,124
  • 25
  • 31
0

I tried everything and nothing worked so here is another solution that finally worked (for me).

I had to check Enable Java EE configuration under Preferences -> Maven -> Jave EE configuration

After that you can check that more entries were added in Deployment assemblies of the project settings.

T3rm1
  • 2,299
  • 5
  • 34
  • 51
0

In my case, I configured an external Maven installation, and I made sure to be using a JDK instead of a JRE (in the eclipse configuration, and in the Server Environment). You can run a Maven Build of the project from eclipse to check everything is working ok.

After that, I updated the maven projects, cleaned and built the projects, cleaned the server, and redeployed the artifacts.

Gerardo Roza
  • 2,746
  • 2
  • 24
  • 33