2 Replies Latest reply on Dec 10, 2012 1:43 AM by Nilesh Thete

    Unable to access data-source in jBoss 7.1.1

    Nilesh Thete Newbie

      Hi,

       

      I am deploying one war file in jboss7.1.1 in standalone deployements. For this datasources are needed. I created datasources in standalone.xml file as shown below.

       

      <datasource jndi-name="java:jboss/datasources/Hibernate" pool-name="hibpool" enabled="true" use-java-context="true">

                          <connection-url>jdbc:mysql://localhost:3307/hibernate</connection-url>

                          <driver>sql</driver>

                          <pool>

                              <prefill>false</prefill>

                              <use-strict-min>false</use-strict-min>

                              <flush-strategy>FailingConnectionOnly</flush-strategy>

                          </pool>

                          <security>

                              <user-name>root</user-name>

                              <password>password</password>

                          </security>

                      </datasource>

                      <datasource jndi-name="java:jboss/datasources/Quartz" pool-name="quartzpool" enabled="true" use-java-context="true">

                          <connection-url>jdbc:mysql://localhost:3307/quartz</connection-url>

                          <driver>sql</driver>

                          <pool>

                              <prefill>false</prefill>

                              <use-strict-min>false</use-strict-min>

                              <flush-strategy>FailingConnectionOnly</flush-strategy>

                          </pool>

                          <security>

                              <user-name>root</user-name>

                              <password>password</password>

                          </security>

                      </datasource>

       

       

      Also I created drivers in standalone.xml as shown

       

                      <driver name="sql" module="com.sqldatabase.sql">

                              <xa-datasource-class>com.mysql.jdbc.jdbc2.optional.MysqlXADataSource</xa-datasource-class>

                          </driver>

       

       

      Problem here is when, I try to access datasource i.e. jboss/datasources/Quartz in JBOSSHOME\biserver-ce\pentaho-solutions\system\xxx.xml file, I am unable to do so...containts of xml file are

       

      <?xml version="1.0" encoding="UTF-8"?>

      <audit-sql>

       

       

        <auditConnection>

          <insertSQL>

          INSERT INTO PRO_AUDIT (JOB_ID, INST_ID, OBJ_ID, OBJ_TYPE, ACTOR, MESSAGE_TYPE, MESSAGE_NAME, MESSAGE_TEXT_VALUE, MESSAGE_NUM_VALUE, DURATION, AUDIT_TIME) values (?,?,?,?,?,?,?,?,?,?,?)

          </insertSQL>

          <JNDI>jboss/datasources/Quartz</JNDI>

        </auditConnection>

       

       

      </audit-sql>

       

      Also I am attaching error logs because of this problem, I know this error is related to my war. but caused since I did not got proper datasource....Can someone help me in this?

       

       

      18:10:30,660 ERROR [org.pentaho.platform.util.logging.Logger] (MSC service thread 1-5) misc-org.pentaho.platform.scheduler.QuartzSystemListener: QuartzSystemListener.ERROR_0006 - Unable to get datasource object: org.pentaho.platform.api.data.DatasourceServiceException: javax.naming.NameNotFoundException: Error looking up jboss/datasources/Quartz, service service jboss.naming.context.java.jboss.datasources.Quartz is not started

                at org.pentaho.platform.engine.services.connection.datasource.dbcp.BaseDatasourceService.getDSBoundName(BaseDatasourceService.java:175) [pentaho-bi-platform-engine-services-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.pentaho.platform.scheduler.QuartzSystemListener.startup(QuartzSystemListener.java:94) [pentaho-bi-platform-scheduler-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.pentaho.platform.engine.core.system.PentahoSystem.notifySystemListenersOfStartup(PentahoSystem.java:342) [pentaho-bi-platform-engine-core-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.pentaho.platform.engine.core.system.PentahoSystem.notifySystemListenersOfStartup(PentahoSystem.java:324) [pentaho-bi-platform-engine-core-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.pentaho.platform.engine.core.system.PentahoSystem.init(PentahoSystem.java:291) [pentaho-bi-platform-engine-core-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.pentaho.platform.engine.core.system.PentahoSystem.init(PentahoSystem.java:208) [pentaho-bi-platform-engine-core-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.pentaho.platform.web.http.context.SolutionContextListener.contextInitialized(SolutionContextListener.java:137) [pentaho-bi-platform-web-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:3392) [jbossweb-7.0.13.Final.jar:]

                at org.apache.catalina.core.StandardContext.start(StandardContext.java:3850) [jbossweb-7.0.13.Final.jar:]

                at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentService.java:90) [jboss-as-web-7.1.1.Final.jar:7.1.1.Final]

                at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811)

                at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746)

                at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [rt.jar:1.6.0_33]

                at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [rt.jar:1.6.0_33]

                at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_33]

      Caused by: javax.naming.NameNotFoundException: Error looking up jboss/datasources/Quartz, service service jboss.naming.context.java.jboss.datasources.Quartz is not started

                at org.jboss.as.naming.ServiceBasedNamingStore.lookup(ServiceBasedNamingStore.java:126)

                at org.jboss.as.naming.ServiceBasedNamingStore.lookup(ServiceBasedNamingStore.java:74)

                at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:178)

                at org.jboss.as.naming.InitialContext.lookup(InitialContext.java:113)

                at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:214)

                at javax.naming.InitialContext.lookup(InitialContext.java:392) [rt.jar:1.6.0_33]

                at org.pentaho.platform.engine.services.connection.datasource.dbcp.BaseDatasourceService.getDSBoundName(BaseDatasourceService.java:140) [pentaho-bi-platform-engine-services-4.5.0-GA.jar:4.5.0-GA.49857]

                ... 14 more

       

       

      18:10:30,682 ERROR [org.pentaho.platform.util.logging.Logger] (MSC service thread 1-5) Error: Pentaho

      18:10:30,683 ERROR [org.pentaho.platform.util.logging.Logger] (MSC service thread 1-5) misc-org.pentaho.platform.engine.core.system.PentahoSystem: PentahoSystem.ERROR_0014 - Error while trying to execute startup sequence for org.pentaho.platform.scheduler.QuartzSystemListener: org.pentaho.platform.api.engine.PentahoSystemException: PentahoSystem.ERROR_0014 - Error while trying to execute startup sequence for org.pentaho.platform.scheduler.QuartzSystemListener

                at org.pentaho.platform.engine.core.system.PentahoSystem.notifySystemListenersOfStartup(PentahoSystem.java:350) [pentaho-bi-platform-engine-core-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.pentaho.platform.engine.core.system.PentahoSystem.notifySystemListenersOfStartup(PentahoSystem.java:324) [pentaho-bi-platform-engine-core-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.pentaho.platform.engine.core.system.PentahoSystem.init(PentahoSystem.java:291) [pentaho-bi-platform-engine-core-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.pentaho.platform.engine.core.system.PentahoSystem.init(PentahoSystem.java:208) [pentaho-bi-platform-engine-core-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.pentaho.platform.web.http.context.SolutionContextListener.contextInitialized(SolutionContextListener.java:137) [pentaho-bi-platform-web-4.5.0-GA.jar:4.5.0-GA.49857]

                at org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:3392) [jbossweb-7.0.13.Final.jar:]

                at org.apache.catalina.core.StandardContext.start(StandardContext.java:3850) [jbossweb-7.0.13.Final.jar:]

                at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentService.java:90) [jboss-as-web-7.1.1.Final.jar:7.1.1.Final]

                at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811)

                at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746)

                at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [rt.jar:1.6.0_33]

                at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [rt.jar:1.6.0_33]

                at java.lang.Thread.run(Thread.java:662) [rt.jar:1.6.0_33]

      Caused by: org.pentaho.platform.api.engine.PentahoSystemException: PentahoSystem.ERROR_0014 - Error while trying to execute startup sequence for org.pentaho.platform.scheduler.QuartzSystemListener

                at org.pentaho.platform.engine.core.system.PentahoSystem.notifySystemListenersOfStartup(PentahoSystem.java:343) [pentaho-bi-platform-engine-core-4.5.0-GA.jar:4.5.0-GA.49857]

                ... 12 more

       

       

      18:10:30,696 ERROR [org.pentaho.platform.util.logging.Logger] (MSC service thread 1-5) Error end:

      18:10:30,698 ERROR [stderr] (MSC service thread 1-5) Pentaho BI Platform server failed to properly initialize. The system will not be available for requests. (Pentaho Platform Engine Core 4.5.0-GA.49857) Fully Qualified Server Url = http://localhost:8080/pentaho/, Solution Path = D:\ForJboss7.1.1\jboss-as-7.1.1.Final\biserver-ce\pentaho-solutions