Jetty slow startup... hibernate issue? - eclipse

I'm running Jetty 8 with Eclipse. After a Java update this morning, JettyLauncher is now taking 6 minutes to start up, as opposed to 10 seconds before. Several of the delays seem to deal with Hibernate (I don't remember seeing too much about Hibernate when Jetty was running at a normal speed). Could anyone confirm or deny that hibernate is causing an issue with the JettyLauncher? Or otherwise pinpoint where this delay is coming from?
The Jetty launch delays the most during these lines in the console output:
5347 [main] INFO org.hibernate.validator.util.Version - Hibernate Validator 4.2.0.Final
...
74022 [main] INFO org.hibernate.impl.SessionFactoryObjectFactory - Not binding factory to JNDI, no JNDI name configured
starting guide stats cache service
97089 [main] INFO org.springframework.beans.factory.config.PropertiesFactoryBean - Loading properties file from ServletContext resource [/WEB-INF/properties/build.properties]
118670 [main] INFO org.springframework.orm.hibernate3.HibernateTransactionManager - Using DataSource [org.springframework.jdbc.datasource.DriverManagerDataSource#16bc6df1] of Hibernate SessionFactory for HibernateTransactionManager
CacheReportsJob.cacheGuideStats()
119649 [main] INFO org.springframework.web.context.ContextLoader - Root WebApplicationContext: initialization completed in 119133 ms
119661 [main] INFO org.eclipse.jetty.server.handler.ContextHandler - started o.e.j.w.WebAppContext{/,file:/C:/Users/MBeatty/Documents/Tortoise%20SVN/Beek%20Checkout%20v2/trunk/server/}
Oct 17, 2013 11:54:22 AM com.sun.faces.config.ConfigureListener contextInitialized
INFO: Initializing Mojarra 2.1.3 (FCS b02) for context ''
Oct 17, 2013 11:54:59 AM com.sun.faces.spi.InjectionProviderFactory createInstance
INFO: JSF1048: PostConstruct/PreDestroy annotations present. ManagedBeans methods marked with these annotations will have said annotations processed.
Oct 17, 2013 11:55:43 AM org.primefaces.webapp.PostConstructApplicationEventListener processEvent
INFO: Running on PrimeFaces 3.2-SNAPSHOT
Oct 17, 2013 11:55:43 AM com.sun.faces.lifecycle.ELResolverInitPhaseListener populateFacesELResolverForJsp
INFO: JSF1027: [null] The ELResolvers for JSF were not registered with the JSP container.

Related

Getting tomcat 404 error when accessing artifactory docker

I created an instance of Artifactoy in docker. I mapped its 8081 port to local 3007 port:
ports:
- "3007:8081"
These are done on a remote server (the docker is running on a remote server on the company network)
When accessing it using http://server-domain-name:3007, i get the following error:
HTTP Status 404 – Not Found
Type Status Report
Message /ui/
Description The origin server did not find a current representation for the target resource or is not willing to disclose that one exists.
Apache Tomcat/8.5.51
but if i run curl http://server-domain-name:3007, i get the following which shows that Artifactory is running:
<!--
~ Artifactory is a binaries repository manager.
~ Copyright (C) 2018 JFrog Ltd.
~
~ Artifactory is free software: you can redistribute it and/or modify
~ it under the terms of the GNU Affero General Public License as published by
~ the Free Software Foundation, either version 3 of the License, or
~ (at your option) any later version.
~
~ Artifactory is distributed in the hope that it will be useful,
~ but WITHOUT ANY WARRANTY; without even the implied warranty of
~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
~ GNU Affero General Public License for more details.
~
~ You should have received a copy of the GNU Affero General Public License
~ along with Artifactory. If not, see <http://www.gnu.org/licenses/>.
-->
<html>
<head>
<meta http-equiv="refresh" content="0;URL=/artifactory">
</head>
<body>
</body>
</html>
I suspect it's something related to artifactory proxy settings, but not sure!
Any idea why I get this error and can not access it??
These are the tomcat logs within the docker container:
/opt/jfrog/artifactory/var/log/tomcat# cat tomcat-catalina-2020-03-24.log
24-Mar-2020 10:57:42.185 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-8081"]
24-Mar-2020 10:57:42.200 INFO [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
24-Mar-2020 10:57:42.208 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-8040"]
24-Mar-2020 10:57:42.209 INFO [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
24-Mar-2020 10:57:42.214 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Catalina]
24-Mar-2020 10:57:42.214 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet Engine: Apache Tomcat/8.5.51
24-Mar-2020 10:57:42.233 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDescriptor Deploying deployment descriptor [/opt/jfrog/artifactory/app/artifactory/tomcat/conf/Catalina/localhost/access.xml]
24-Mar-2020 10:57:42.233 INFO [localhost-startStop-2] org.apache.catalina.startup.HostConfig.deployDescriptor Deploying deployment descriptor [/opt/jfrog/artifactory/app/artifactory/tomcat/conf/Catalina/localhost/artifactory.xml]
24-Mar-2020 10:57:42.252 WARNING [localhost-startStop-2] org.apache.catalina.startup.HostConfig.deployDescriptor A docBase [/opt/jfrog/artifactory/app/artifactory/tomcat/webapps/artifactory.war] inside the host appBase has been specified, and will be ignored
24-Mar-2020 10:57:42.252 WARNING [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDescriptor A docBase [/opt/jfrog/artifactory/app/artifactory/tomcat/webapps/access.war] inside the host appBase has been specified, and will be ignored
24-Mar-2020 10:57:50.670 INFO [localhost-startStop-2] org.apache.catalina.startup.HostConfig.deployDescriptor Deployment of deployment descriptor [/opt/jfrog/artifactory/app/artifactory/tomcat/conf/Catalina/localhost/artifactory.xml] has finished in [8,436] ms
24-Mar-2020 10:57:52.693 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDescriptor Deployment of deployment descriptor [/opt/jfrog/artifactory/app/artifactory/tomcat/conf/Catalina/localhost/access.xml] has finished in [10,460] ms
24-Mar-2020 10:57:52.694 INFO [localhost-startStop-2] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [/opt/jfrog/artifactory/app/artifactory/tomcat/webapps/ROOT]
24-Mar-2020 10:57:52.705 INFO [localhost-startStop-2] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [/opt/jfrog/artifactory/app/artifactory/tomcat/webapps/ROOT] has finished in [11] ms
24-Mar-2020 10:57:52.708 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8081"]
24-Mar-2020 10:57:52.724 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8040"]
24-Mar-2020 12:20:14.606 INFO [main] org.apache.catalina.core.StandardServer.await A valid shutdown command was received via the shutdown port. Stopping the Server instance.
24-Mar-2020 12:20:14.606 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-8081"]
24-Mar-2020 12:20:14.612 INFO [main] org.apache.coyote.AbstractProtocol.pause Pausing ProtocolHandler ["http-nio-8040"]
24-Mar-2020 12:20:14.617 INFO [main] org.apache.catalina.core.StandardService.stopInternal Stopping service [Catalina]
24-Mar-2020 12:20:19.751 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-8081"]
24-Mar-2020 12:20:19.751 INFO [main] org.apache.coyote.AbstractProtocol.stop Stopping ProtocolHandler ["http-nio-8040"]
24-Mar-2020 12:20:19.752 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-8081"]
24-Mar-2020 12:20:19.753 INFO [main] org.apache.coyote.AbstractProtocol.destroy Destroying ProtocolHandler ["http-nio-8040"]
24-Mar-2020 12:20:26.296 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-8081"]
24-Mar-2020 12:20:26.312 INFO [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
24-Mar-2020 12:20:26.320 INFO [main] org.apache.coyote.AbstractProtocol.init Initializing ProtocolHandler ["http-nio-8040"]
24-Mar-2020 12:20:26.321 INFO [main] org.apache.tomcat.util.net.NioSelectorPool.getSharedSelector Using a shared selector for servlet write/read
24-Mar-2020 12:20:26.326 INFO [main] org.apache.catalina.core.StandardService.startInternal Starting service [Catalina]
24-Mar-2020 12:20:26.326 INFO [main] org.apache.catalina.core.StandardEngine.startInternal Starting Servlet Engine: Apache Tomcat/8.5.51
24-Mar-2020 12:20:26.339 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDescriptor Deploying deployment descriptor [/opt/jfrog/artifactory/app/artifactory/tomcat/conf/Catalina/localhost/access.xml]
24-Mar-2020 12:20:26.339 INFO [localhost-startStop-2] org.apache.catalina.startup.HostConfig.deployDescriptor Deploying deployment descriptor [/opt/jfrog/artifactory/app/artifactory/tomcat/conf/Catalina/localhost/artifactory.xml]
24-Mar-2020 12:20:26.363 WARNING [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDescriptor A docBase [/opt/jfrog/artifactory/app/artifactory/tomcat/webapps/access.war] inside the host appBase has been specified, and will be ignored
24-Mar-2020 12:20:26.363 WARNING [localhost-startStop-2] org.apache.catalina.startup.HostConfig.deployDescriptor A docBase [/opt/jfrog/artifactory/app/artifactory/tomcat/webapps/artifactory.war] inside the host appBase has been specified, and will be ignored
24-Mar-2020 12:20:28.904 INFO [localhost-startStop-2] org.apache.catalina.startup.HostConfig.deployDescriptor Deployment of deployment descriptor [/opt/jfrog/artifactory/app/artifactory/tomcat/conf/Catalina/localhost/artifactory.xml] has finished in [2,564] ms
24-Mar-2020 12:20:35.030 INFO [localhost-startStop-1] org.apache.catalina.startup.HostConfig.deployDescriptor Deployment of deployment descriptor [/opt/jfrog/artifactory/app/artifactory/tomcat/conf/Catalina/localhost/access.xml] has finished in [8,691] ms
24-Mar-2020 12:20:35.031 INFO [localhost-startStop-2] org.apache.catalina.startup.HostConfig.deployDirectory Deploying web application directory [/opt/jfrog/artifactory/app/artifactory/tomcat/webapps/ROOT]
24-Mar-2020 12:20:35.048 INFO [localhost-startStop-2] org.apache.catalina.startup.HostConfig.deployDirectory Deployment of web application directory [/opt/jfrog/artifactory/app/artifactory/tomcat/webapps/ROOT] has finished in [17] ms
24-Mar-2020 12:20:35.050 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8081"]
24-Mar-2020 12:20:35.060 INFO [main] org.apache.coyote.AbstractProtocol.start Starting ProtocolHandler ["http-nio-8040"]
/opt/jfrog/artifactory/var/log/tomcat# cat tomcat-localhost-2020-03-24.log
24-Mar-2020 10:57:42.907 INFO [localhost-startStop-1] org.apache.catalina.core.ApplicationContext.log 1 Spring WebApplicationInitializers detected on classpath
24-Mar-2020 10:57:45.680 INFO [localhost-startStop-1] org.apache.catalina.core.ApplicationContext.log Initializing Spring embedded WebApplicationContext
24-Mar-2020 12:20:14.651 INFO [localhost-startStop-3] org.apache.catalina.core.ApplicationContext.log Closing Spring root WebApplicationContext
24-Mar-2020 12:20:26.965 INFO [localhost-startStop-1] org.apache.catalina.core.ApplicationContext.log 1 Spring WebApplicationInitializers detected on classpath
24-Mar-2020 12:20:29.632 INFO [localhost-startStop-1] org.apache.catalina.core.ApplicationContext.log Initializing Spring embedded WebApplicationContext
Update:
If I ssh into the docker container and run
curl --head http://localhost:8081/artifactory/webapp/#/login
I get this:
HTTP/1.1 200 OK
Server: Artifactory/7.3.2
X-Artifactory-Id: 7c88d7b6c0e91efc:e615a11:17111dedc15:-8000
X-Artifactory-Node-Id: 2dd09e552f22
Cache-Control: no-store,max-age=0
X-FRAME-OPTIONS: DENY
Accept-Ranges: bytes
ETag: W/"2239-1584804418000"
Last-Modified: Sat, 21 Mar 2020 15:26:58 GMT
Content-Type: text/html
Content-Length: 2239
Date: Wed, 25 Mar 2020 13:50:46 GMT
it looks like artifactory is working ok but not accessible when port 8081 is mapped to 3007 external port.
Can this be related to Apache Tomcat config inside the docker container?

Tapestry AppModule not added by RegistryBuilder for one project, works fine for another

I'm using Eclipse Mars, Tomcat7, Java8, Sysdeo DevLoader and I followed a Tynamo tutorial to configure the tomcat plugin.
I have two almost identical Tapestry projects. One app works fine the other won't serve any pages, throwing:
SEVERE: Servlet.service() for servlet [default] in context with path [/admin] threw exception
java.lang.RuntimeException: Exception constructing service 'WebSecurityManager': Error invoking constructor public org.tynamo.security.services.TapestryRealmSecurityManager(org.tynamo.security.Authenticator,org.apache.shiro.mgt.SubjectFactory,org.apache.shiro.mgt.RememberMeManager,java.util.Collection): Realms collection argument cannot be empty.
at org.apache.tapestry5.ioc.internal.services.JustInTimeObjectCreator.obtainObjectFromCreator(JustInTimeObjectCreator.java:75)
...
Caused by: java.lang.IllegalArgumentException: Realms collection argument cannot be empty.
at org.apache.shiro.mgt.RealmSecurityManager.setRealms(RealmSecurityManager.java:78)
at org.tynamo.security.services.TapestryRealmSecurityManager.<init>(TapestryRealmSecurityManager.java:31)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:422)
at org.apache.tapestry5.ioc.internal.util.ConstructorInvoker.invoke(ConstructorInvoker.java:48)
... 50 more
The problem seems to stem from my AppModule.addRealms not being called in the problem app before the security manager tries to get the Subject. In fact it seems that one of the apps enjoys the 'Tapestry treatment' and the other does not. Here's the one that works:
Nov 05, 2015 11:45:53 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/bray.xml
Nov 05, 2015 11:45:53 AM org.apache.catalina.core.StandardContext setPath
WARNING: A context path must either be an empty string or start with a '/'. The path [bray] does not meet these criteria and has been changed to [/bray]
Nov 05, 2015 11:45:53 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Context/Loader} Setting property 'debug' to '1' did not find a matching property.
Nov 05, 2015 11:45:53 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Context/Loader} Setting property 'useSystemClassLoaderAsParent' to 'false' did not find a matching property.
[DevLoader] Starting DevLoader
[DevLoader] projectdir=/home/claude/git/bray/src/main/webapp
[DevLoader] added file:/home/claude/git/bray/target/classes/
...
[INFO] ioc.RegistryBuilder Adding module definition for class com.mydomain.services.AppModule
[INFO] TapestryModule.ComponentClassResolver Available pages (16):
(blank): com.mydomain.pages.Index
About: com.mydomain.pages.About
Then I see the nice "hello" from Tapestry and my other project (admin) comes up:
...
Application 'app' (version 1.0-SNAPSHOT) startup time: 172 ms to build IoC Registry, 541 ms overall.
______ __ ____
/_ __/__ ____ ___ ___ / /_______ __ / __/
/ / / _ `/ _ \/ -_|_-</ __/ __/ // / /__ \
/_/ \_,_/ .__/\__/___/\__/_/ \_, / /____/
/_/ /___/ 5.3.8 (development mode)
Nov 05, 2015 11:45:58 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/admin.xml
Nov 05, 2015 11:45:58 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Context/Loader} Setting property 'debug' to '1' did not find a matching property.
Nov 05, 2015 11:45:58 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Context/Loader} Setting property 'useSystemClassLoaderAsParent' to 'false' did not find a matching property.
[DevLoader] Starting DevLoader
[DevLoader] projectdir=/home/claude/git/tegu/admin/src/main/webapp
...
Nov 05, 2015 11:45:58 AM org.apache.catalina.deploy.WebXml setVersion
WARNING: Unknown version string [3.1]. Default version will be used.
log4j:WARN No appenders could be found for logger (org.apache.tapestry5.ioc.RegistryBuilder).
log4j:WARN Please initialize the log4j system properly.
Nov 05, 2015 11:46:02 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/manager.xml
Nov 05, 2015 11:46:02 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/docs.xml
Nov 05, 2015 11:46:02 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/host-manager.xml
Nov 05, 2015 11:46:02 AM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /etc/tomcat7/Catalina/localhost/examples.xml
I expected to see something like this after my admin.xml descriptor is deployed:
[INFO] ioc.RegistryBuilder Adding module definition for class com.myotherdomain.admin.services.AppModule
[INFO] TapestryModule.ComponentClassResolver Available pages (16):
...but instead there is silence. I can't see anything different in the two apps that would cause one to work and the other to fail. Where should I look?
The DevLoader Classpath was wrong. Fixing that fixed everything.
The DevLoader Classpath did not include the path /myapp/target/classes -- and that's where my app's AppModule was (/myapp/target/classes/com/mydomain/myapp/services/AppModule.class to be exact). This can be fixed in Project -> Properties -> Tomcat and checking the checkbox for the right path. The wrong configuration can also be seen in a file next to the project's WEB-INF called .#webclasspath which spells out the complete path (the relative path is shown in the config page). After fixing the setup, start Tomcat and .#webclasspath should be automatically updated.

Tomcat configuration using embedded ActiveMQ JMS

I have Tomcat 7.0.42 and ActiveMQ 5.10 and have added the following resources to my context.xml file:
<Resource
auth="Container"
brokerName="MyActiveMQBrokerXML"
description="JMS Connection Factory"
factory="org.apache.activemq.jndi.JNDIReferenceFactory"
name="jms/ConnectionFactory"
type="org.apache.activemq.ActiveMQConnectionFactory"
useEmbeddedBroker="true"
brokerURL="vm://localhost?brokerConfig=xbean:activemq.xml"
/>
When starting Tomcat via is built-in startup script I get the following in the console out-put.
2015-01-27 09:49:24,064 [localhost-startStop-1] INFO org.apache.activemq.store.kahadb.plist.PListStoreImpl- PListStore:[C:\tomcat\apache-tomcat-7.0.57\bin\acti vemq-data\MyActiveMQBroker\tmp_storage] started
2015-01-27 09:49:24,068 [localhost-startStop-1] INFO org.apache.activemq.broker.BrokerService- Using Persistence Adapter: KahaDBPersistenceAdapter[C:\tomcat\ap ache-tomcat-7.0.57\bin\activemq-data\MyActiveMQBroker\KahaDB]
2015-01-27 09:49:24,471 [localhost-startStop-1] INFO org.apache.activemq.store.kahadb.MessageDatabase- KahaDB is version 5
2015-01-27 09:49:24,491 [localhost-startStop-1] INFO org.apache.activemq.store.kahadb.MessageDatabase- Recovering from the journal ...
2015-01-27 09:49:24,492 [localhost-startStop-1] INFO org.apache.activemq.store.kahadb.MessageDatabase- Recovery replayed 3 operations from the journal in 0.01 seconds.
2015-01-27 09:49:24,663 [localhost-startStop-1] INFO org.apache.activemq.broker.BrokerService- Apache ActiveMQ 5.10.0 (MyActiveMQBroker, ID:Jacob-PC-55865-1422 373764525-0:1) is starting
2015-01-27 09:49:24,707 [localhost-startStop-1] INFO org.apache.activemq.broker.TransportConnector- Connector vm://localhost?brokerConfig=xbean:activemq.xml st arted
2015-01-27 09:49:24,707 [localhost-startStop-1] INFO org.apache.activemq.broker.BrokerService- Apache ActiveMQ 5.10.0 (MyActiveMQBroker, ID:Jacob-PC-55865-1422 373764525-0:1) started
2015-01-27 09:49:24,708 [localhost-startStop-1] INFO org.apache.activemq.broker.BrokerService- For help or more information please see: http://activemq.apache. org
2015-01-27 09:49:24,711 [localhost-startStop-1] ERROR org.apache.activemq.broker.BrokerService- Memory Usage for the Broker (1024 mb) is more than the maximum a vailable for the JVM: 247 mb - resetting to 70% of maximum available: 173 mb
2015-01-27 09:49:24,728 [localhost-startStop-1] WARN org.apache.activemq.broker.BrokerRegistry- Broker localhost not started so using MyActiveMQBroker instead Jan 27, 2015 9:49:24 AM org.apache.catalina.startup.HostConfig deployDirectory
It appears to me that tomcat is not looking for the activemq.xml file or is at least not using it. This exact configuration works if I start tomcat through eclipse, but that is not a viable option for a production system.
I found that if deploying into production you have to use the absolute path to the file to get Tomcat to find the activemq.xml file. Although using the relative path is supposed to work, I could never get it to.
brokerURL="vm://localhost?brokerConfig=xbean:activemq.xml"
Supposedly only works if you've added to 'activemq.xml' to the class path. Note the presence of 'file' in 'xbean:file:/some/path/activemq.xml'.
<Resource id="MyJmsResourceAdapter" type="ActiveMQResourceAdapter">
BrokerXmlConfig = xbean:file:/usr/share/apache-tomee-plus-8.0.0-M1/conf/activemq.xml
ServerUrl = tcp://localhost:61616
</Resource>

Tomcat Not Starting after adding postgresql jar

I am using an apache tomcat server with eclipse. When I added the postgresql jar to tomcat, it fails to start and ends on timeout with the message: "Server Tomcat v7.0 Server at localhost was unable to start within 45 seconds. If the server requires more time, try increasing the timeout in the server editor". The console output is shown below:
Sep 04, 2013 12:39:50 AM 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 (x86)\Java\jre7\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:/Program Files (x86)/Java/jre7/bin/client;C:/Program Files (x86)/Java/jre7/bin;C:/Program Files (x86)/Java/jre7/lib/i386;C:\Program Files\MiKTeX 2.9\miktex\bin;C:\Program Files (x86)\MiKTeX 2.9\miktex\bin;C:\Program Files (x86)\PC Connectivity Solution\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\QuickTime\QTSystem\;C:\Windows\system32\gs\gs8.71\bin;C:\svn\bin;E:\apache-maven-3.0.5\bin;C:\Program Files\Java\jdk1.7.0_02\bin;C:\JExcel;C:\Program Files (x86)\OpenSSH\bin;C:\osmdata;C:\osm2pgsql;C:\osm2pgsql\x64\;C:\Program Files\MATLAB\R2010a\runtime\win64;C:\Program Files\MATLAB\R2010a\bin;E:\eclipse;;.
Sep 04, 2013 12:39:50 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:scriptsynth' did not find a matching property.
Sep 04, 2013 12:39:50 AM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
Sep 04, 2013 12:39:50 AM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
Sep 04, 2013 12:39:50 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 1162 ms
Sep 04, 2013 12:39:50 AM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Sep 04, 2013 12:39:50 AM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.41
Sep 04, 2013 12:39:57 AM org.apache.catalina.core.ApplicationContext log
INFO: No Spring WebApplicationInitializer types detected on classpath
Sep 04, 2013 12:39:57 AM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Spring root WebApplicationContext
00:39:57.572 [localhost-startStop-1] INFO o.s.web.context.ContextLoader - Root WebApplicationContext: initialization started
00:39:57.761 [localhost-startStop-1] INFO o.s.w.c.s.XmlWebApplicationContext - Refreshing Root WebApplicationContext: startup date [Wed Sep 04 00:39:57 IST 2013]; root of context hierarchy
00:39:57.884 [localhost-startStop-1] INFO o.s.b.f.xml.XmlBeanDefinitionReader - Loading XML bean definitions from class path resource [applicationContext.xml]
00:39:58.656 [localhost-startStop-1] INFO o.s.w.c.s.XmlWebApplicationContext - Bean 'org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter#1c212b0' of type [class org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
00:39:58.727 [localhost-startStop-1] INFO o.s.w.c.s.XmlWebApplicationContext - Bean 'dataSource' of type [class org.springframework.jndi.JndiObjectFactoryBean] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
00:39:58.727 [localhost-startStop-1] INFO o.s.w.c.s.XmlWebApplicationContext - Bean 'dataSource' of type [class org.apache.tomcat.dbcp.dbcp.BasicDataSource] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
00:39:58.752 [localhost-startStop-1] INFO o.s.o.j.LocalContainerEntityManagerFactoryBean - Building JPA container EntityManagerFactory for persistence unit 'default'
00:39:59.167 [localhost-startStop-1] INFO o.h.annotations.common.Version - HCANN000001: Hibernate Commons Annotations {4.0.2.Final}
00:39:59.182 [localhost-startStop-1] INFO org.hibernate.Version - HHH000412: Hibernate Core {4.2.5.Final}
00:39:59.185 [localhost-startStop-1] INFO org.hibernate.cfg.Environment - HHH000206: hibernate.properties not found
00:39:59.188 [localhost-startStop-1] INFO org.hibernate.cfg.Environment - HHH000021: Bytecode provider name : javassist
00:39:59.236 [localhost-startStop-1] INFO org.hibernate.ejb.Ejb3Configuration - HHH000204: Processing PersistenceUnitInfo [
name: default
...]
00:39:59.461 [localhost-startStop-1] INFO o.h.s.j.c.i.ConnectionProviderInitiator - HHH000130: Instantiating explicit connection provider: org.hibernate.ejb.connection.InjectedDataSourceConnectionProvider
When I remove the postgresql jar from tomcat's lib folder, it starts fine as before.
PostgreSQL seems to be running as I can conenct to it from pgAdmin
Any ideas on how to fix this?
hey i had this same problem i hope this could help i just added a new jar into Tomcat directory.... a 400 kb a small one. and i sorted in the tomcat/lib/directory to bigger to smaller and i get the start time double it from 30 seconds to 60 seconds. was driving me nuts. later i sorted the tomcat/lib/directory from smaller to bigger and get back my 32 seconds i think here is the problem is called branch predictionplease take a look to this topics.
Why is it faster to process a sorted array than an unsorted array?
and
http://en.wikipedia.org/wiki/Branch_predictor
i hope really can helps somebody..

Deploying grails 2.0.3 application to cloudfoundry without cloud foundry grails-plugin?

I'm able to deploy my grails 2.0.3 app with the cloud foundry grails plugin and cf-push to the cloud and everything works fine.
Now i want to use the sts/eclipse cloud foundry extension to deploy with eclipse (not with grails command cf-push!) and see the server instances in server view and so on.
I create a new cloudfoundry instance with the eclipse plugin and it deploys but aborts with error message:
May 14, 2012 10:39:21 AM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-19036
May 14, 2012 10:39:21 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 377 ms
May 14, 2012 10:39:21 AM org.apache.catalina.realm.JAASRealm setContainer
INFO: Set JAAS app name Catalina
May 14, 2012 10:39:21 AM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
May 14, 2012 10:39:21 AM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.35
May 14, 2012 10:39:21 AM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory ROOT
Configuring Spring Security Core ...
... finished configuring Spring Security Core
May 14, 2012 10:39:32 AM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
May 14, 2012 10:39:32 AM org.apache.catalina.core.StandardContext start
SEVERE: Context [] startup failed due to previous errors
May 14, 2012 10:39:32 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [net.sf.ehcache.CacheManager#1edb587] but has failed to stop it. This is very likely to create a memory leak.
May 14, 2012 10:39:32 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [projectBee.Requestmap.data] but has failed to stop it. This is very likely to create a memory leak.
May 14, 2012 10:39:32 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [projectBee.Role.data] but has failed to stop it. This is very likely to create a memory leak.
May 14, 2012 10:39:32 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [org.hibernate.cache.UpdateTimestampsCache.data] but has failed to stop it. This is very likely to create a memory leak.
May 14, 2012 10:39:32 AM org.apache.catalina.loader.WebappClassLoader clearReferencesThreads
SEVERE: The web application [] appears to have started a thread named [org.hibernate.cache.StandardQueryCache.data] but has failed to stop it. This is very likely to create a memory leak.
Stopping Tomcat because the context stopped.
Is here somebody who knows a solution for this problem? Thank you!
You need to look at the real log files which will have the stacktrace and detailed error messages. Use the vmc commandline client or STS. There is a /logs folder which probably doesn't have what you want, but also a /tomcat/logs which probably does. Also check out stacktrace.log.