0 Replies Latest reply on Aug 4, 2014 9:20 AM by kusuma thatavarthi

    JBOSS EAP 6.2.0 Error  Occured while shutdown-Unscheduling jobs

    kusuma thatavarthi Newbie

      Hi,

       

      I am facing job unscheduling issue while shutting down server(Ctrl+C) .

      Please find my post here https://issues.jboss.org/browse/JBEAP-68.

       

      I am doing the following in ContextDestroyed

       

      jobScheduler.unscheduleJob(PaaSConsoleUtil.PAAS_CLEANUP_JOB_NAME, PaaSConsoleUtil.JOB_GROUP);
      jobScheduler.shutdown(true);
      ConnectionPool.clear();
      ConnectorUtils.shutdown();
      SyncEventListenerUtil.shutdownThreadPool();
      ConsoleContextUtil consoleUtil = new ConsoleContextUtil(logger, false);
      consoleUtil.consoleContextDestroyed();
      

      For reference:

      http://stackoverflow.com/questions/24776554/error-occurred-while-unscheduling-jobs.

      12:39:50,020 ERROR [com.kony.sync.console.job.scheduler.ConsoleJobScheduler] (ServerService Thread Pool – 20) Error occurred while unscheduling jobs for application ID:PaaSJobs: org.qu

      artz.JobPersistenceException: Failed to obtain DB connection from data source 'syncQuartzDS': java.sql.SQLException: Could not retrieve datasource via JNDI url 'java:jboss/datasources/C

      onsoleDB' java.sql.SQLException: javax.resource.ResourceException: IJ000451: The connection manager is shutdown: java:jboss/datasources/ConsoleDB [See nested exception: java.sql.SQLExce

      ption: Could not retrieve datasource via JNDI url 'java:jboss/datasources/ConsoleDB' java.sql.SQLException: javax.resource.ResourceException: IJ000451: The connection manager is shutdow

      n: java:jboss/datasources/ConsoleDB]

      at org.quartz.impl.jdbcjobstore.JobStoreSupport.getConnection(JobStoreSupport.java:715) [quartz-all-1.8.6.jar:]

      at org.quartz.impl.jdbcjobstore.JobStoreTX.getNonManagedTXConnection(JobStoreTX.java:69) [quartz-all-1.8.6.jar:]

      at org.quartz.impl.jdbcjobstore.JobStoreSupport.executeInNonManagedTXLock(JobStoreSupport.java:3785) [quartz-all-1.8.6.jar:]

      at org.quartz.impl.jdbcjobstore.JobStoreTX.executeInLock(JobStoreTX.java:90) [quartz-all-1.8.6.jar:]

      at org.quartz.impl.jdbcjobstore.JobStoreSupport.removeTrigger(JobStoreSupport.java:1458) [quartz-all-1.8.6.jar:]

      at org.quartz.core.QuartzScheduler.unscheduleJob(QuartzScheduler.java:965) [quartz-all-1.8.6.jar:]

      at org.quartz.impl.StdScheduler.unscheduleJob(StdScheduler.java:290) [quartz-all-1.8.6.jar:]

      at com.kony.sync.console.job.scheduler.ConsoleJobScheduler.unscheduleJob(ConsoleJobScheduler.java:225) [syncconsole.jar:]

      at com.kony.sync.services.context.SyncContextListener.contextDestroyed(SyncContextListener.java:221) [classes:]

      at org.apache.catalina.core.StandardContext.listenerStop(StandardContext.java:3427) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]

      at org.apache.catalina.core.StandardContext.stop(StandardContext.java:3920) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]

      at org.jboss.as.web.deployment.WebDeploymentService.doStop(WebDeploymentService.java:171) [jboss-as-web-7.3.0.Final-redhat-14.jar:7.3.0.Final-redhat-14]

      at org.jboss.as.web.deployment.WebDeploymentService.access$100(WebDeploymentService.java:60) [jboss-as-web-7.3.0.Final-redhat-14.jar:7.3.0.Final-redhat-14]

      at org.jboss.as.web.deployment.WebDeploymentService$2.run(WebDeploymentService.java:113) [jboss-as-web-7.3.0.Final-redhat-14.jar:7.3.0.Final-redhat-14]

      at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [rt.jar:1.6.0_26]

      at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source) [rt.jar:1.6.0_26]

      at java.util.concurrent.FutureTask.run(Unknown Source) [rt.jar:1.6.0_26]

      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) [rt.jar:1.6.0_26]

      at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [rt.jar:1.6.0_26]

      at java.lang.Thread.run(Unknown Source) [rt.jar:1.6.0_26]

      at org.jboss.threads.JBossThread.run(JBossThread.java:122)

      Caused by: java.sql.SQLException: Could not retrieve datasource via JNDI url 'java:jboss/datasources/ConsoleDB' java.sql.SQLException: javax.resource.ResourceException: IJ000451: The co

      nnection manager is shutdown: java:jboss/datasources/ConsoleDB

      at org.quartz.utils.JNDIConnectionProvider.getConnection(JNDIConnectionProvider.java:163) [quartz-all-1.8.6.jar:]

      at org.quartz.utils.DBConnectionManager.getConnection(DBConnectionManager.java:109) [quartz-all-1.8.6.jar:]

      at org.quartz.impl.jdbcjobstore.JobStoreSupport.getConnection(JobStoreSupport.java:712) [quartz-all-1.8.6.jar:]

      ... 20 more 

      Terminate batch job (Y/N)?

      Help Would be appreciated.

      Thanks,

      Kusuma