INFO: Illegal access: this web application instance has been stopped already. Could not load java.util.concurrent.ScheduledFuture. The eventual following stack trace is caused by an error thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access, and has no functional impact.
java.lang.IllegalStateException
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1776)
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1734)
at com.zaxxer.hikari.pool.PoolEntry.close(PoolEntry.java:173)
at com.zaxxer.hikari.pool.HikariPool.closeConnection(HikariPool.java:411)
at com.zaxxer.hikari.pool.HikariPool.softEvictConnection(HikariPool.java:525)
at com.zaxxer.hikari.pool.HikariPool.access$200(HikariPool.java:66)
at com.zaxxer.hikari.pool.HikariPool$2.run(HikariPool.java:441)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
Aug 29, 2016 12:43:22 PM org.apache.catalina.loader.WebappClassLoaderBase loadClass
INFO: Illegal access: this web application instance has been stopped already. Could not load com.zaxxer.hikari.pool.HikariPool$1. The eventual following stack trace is caused by an error thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access, and has no functional impact.
java.lang.IllegalStateException
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1776)
at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1734)
at com.zaxxer.hikari.pool.HikariPool.closeConnection(HikariPool.java:412)
at com.zaxxer.hikari.pool.HikariPool.softEvictConnection(HikariPool.java:525)
at com.zaxxer.hikari.pool.HikariPool.access$200(HikariPool.java:66)
at com.zaxxer.hikari.pool.HikariPool$2.run(HikariPool.java:441)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
Since one week i was facing this problem....Please help me
Here is the context.xml:
<?xml version="1.0" encoding="UTF-8"?>
<Context antiJARLocking="true" path="/SpringmvcDPCP">
<Resource name="jdbc/MyLocalDB"
auth="Container"
factory="com.zaxxer.hikari.HikariJNDIFactory"
maxActive="100"
maxIdle="30"
maxWait="10000"
connectionTimeout="30000"
idleTimeout= "300000"
maxLifetime="600000"
type="javax.sql.DataSource"
dataSourceClassName="com.mysql.jdbc.jdbc2.optional.MysqlDataSource"
dataSource.url="jdbc:mysql://localhost:3306/Spring"
dataSource.user="root"
dataSource.password="gaian"
dataSource.cachePrepStmts="true"
dataSource.prepStmtCacheSize="250"
dataSource.prepStmtCacheSqlLimit="2048"
/>
</Context>
Here is the web.xml :
<?xml version="1.0" encoding="UTF-8"?>
default-init-method="init"
default-destroy-method="cleanUp">
<context:component-scan base-package="com.controller"/>
<mvc:annotation-driven/>
<bean class="org.springframework.web.servlet.view.InternalResourceViewResolver">
<property name="prefix" value="/WEB-INF/jsp/"></property>
<property name="suffix" value=".jsp"></property>
</bean>
<cache:annotation-driven />
<bean id="cacheManager" class="org.springframework.cache.ehcache.EhCacheCacheManager" p:cache-manager-ref="ehcache" />
<bean id="ehcache" class="org.springframework.cache.ehcache.EhCacheManagerFactoryBean" p:configLocation="/WEB-INF/ehcache.xml" />
<jee:jndi-lookup id="ds" jndi-name="java:/comp/env/jdbc/MyLocalDB" expected-type="javax.sql.DataSource" />
<bean id="jt" class="org.springframework.jdbc.core.JdbcTemplate">
<property name="dataSource" ref="ds"></property>
</bean>
<bean id="dao" class="com.dao.EmployeeDAO" destroy-method="close" >
<property name="template" ref="jt"></property>
</bean>
</beans>
Lastly controller class :
@Controller
public class EmployeeController {
private Logger LOGGER = Logger.getLogger(EmployeeController.class);
@Autowired
EmployeeDAO empDao;
@RequestMapping(value = "/viewemp", method = RequestMethod.GET)
public ModelAndView viewEmp() throws IOException, SQLException {
List<Employee> listEmp = empDao.list();
return new ModelAndView("viewemp", "list", listEmp);
}