title: Cannot deploy application on Tomcat 7 Due to "invalid Lifecycle transition was attempted " error
body: <p>i've got  aproblem! i'm trying to install my webapp on my tomcat server 7 installation but it keeps on saying that it cannot deploy my app due to "invalid Lifecycle transition was attempted".</p>
  
  <p>here's my catalina log error:</p>
  
  <pre><code>org.apache.catalina.LifecycleException: An invalid Lifecycle transition was attempted       ([before_destroy]) for component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/myapp]] in state [STARTED]
  at org.apache.catalina.util.LifecycleBase.invalidTransition(LifecycleBase.java:409)
  at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:299)
  at org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java:1041)
  at org.apache.catalina.core.ContainerBase.destroyInternal(ContainerBase.java:1234)
  at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:305)
  at org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java:1041)
  at org.apache.catalina.core.ContainerBase.destroyInternal(ContainerBase.java:1234)
  at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:305)
  at org.apache.catalina.core.StandardService.destroyInternal(StandardService.java:593)
  at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:305)
  at org.apache.catalina.core.StandardServer.destroyInternal(StandardServer.java:822)
  at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:305)
  at org.apache.catalina.startup.Catalina.stop(Catalina.java:765)
  at org.apache.catalina.startup.Catalina$CatalinaShutdownHook.run(Catalina.java:910)
  </code></pre>
  
  <p>I've tryied even to delete manually "myapp" folder and ".war" into tomcat's webapp folder (after turning off tomcat) but it doesn't resolve anything.</p>
  
  <p>i tryied also to redeploy my oldest .war files of the app but it won't start at all.</p>
  
  <p>Someone has got any ideas?</p>
  
  <p>thanks in advance</p>