0 Replies Latest reply on Aug 27, 2015 5:58 AM by c00823ue

    How to run jbpm6 project on tomcat7?

    c00823ue

      I already setup a jbpm6 project running on tomcat7 by following this article(jBPM6 - Tomcat 7 - Web Example). Then I successfully change default h2 database to mysql database. But when I try to run my another jbpm6 project, in this project I access mysql database by jndi ,under the same environment, mysql database is not initialized. (project name is rewards-basic)  I can run rewards-basic project on eap6.4 successfully, the mysql tables is automatically add by jndi.

       

      In order to run this project on tomcat7, I change line01 to line02 in persistence.xml.

       

           <jta-data-source>java:jboss/datasources/jbpmDS</jta-data-source>    
          <!--jta-data-source>java:/comp/env/jdbc/jbpm-ds1</jta-data-source-->  
      

       

       

      Moreover, I add the following lines in WEB_INF/web.xml. Do I need to delete jboss-web.xml file?

      <resource-env-ref>
             <resource-env-ref-name>jdbc/jbpm-ds1</resource-env-ref-name>
             <resource-env-ref-type>javax.sql.DataSource</resource-env-ref-type>
          </resource-env-ref>
      
      

       

      I already check that the rewards-basic.xml is under /usr/local/tomcat7-2/conf/Catalina/localhost. The project is successfully running on tomcat7.

       

       

       

      The following is log when I run another jbpm6 project on tomcat7. Can someone help me? THX!

       

      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Server version:        Apache Tomcat/7.0.64
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Server built:          Aug 19 2015 17:18:06 UTC
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Server number:         7.0.64.0
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: OS Name:               Linux
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: OS Version:            2.6.32-358.el6.x86_64
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Architecture:          amd64
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Java Home:             /usr/lib/jvm/jdk1.7.0_51/jre
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: JVM Version:           1.7.0_51-b13
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: JVM Vendor:            Oracle Corporation
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: CATALINA_BASE:         /usr/local/tomcat7-2
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: CATALINA_HOME:         /usr/local/tomcat7-2
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Command line argument: -Djava.util.logging.config.file=/usr/local/tomcat7-2/conf/logging.properties
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Command line argument: -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Command line argument: -XX:MaxPermSize=1024m
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Command line argument: -Dhttp.nonProxyHosts=localhost|127.0.0.1|localhost.localdomain
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Command line argument: -Djava.endorsed.dirs=/usr/local/tomcat7-2/endorsed
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Command line argument: -Dcatalina.base=/usr/local/tomcat7-2
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Command line argument: -Dcatalina.home=/usr/local/tomcat7-2
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.VersionLoggerListener log
      資訊: Command line argument: -Djava.io.tmpdir=/usr/local/tomcat7-2/temp
      八月 27, 2015 5:14:11 下午 org.apache.catalina.core.AprLifecycleListener lifecycleEvent
      資訊: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: /usr/lib/jvm/jdk1.7.0_51/jre/lib/amd64:/usr/lib/jvm/jdk1.7.0_51/jre/lib/i386::/usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib
      八月 27, 2015 5:14:11 下午 org.apache.coyote.AbstractProtocol init
      資訊: Initializing ProtocolHandler ["http-bio-8087"]
      八月 27, 2015 5:14:11 下午 org.apache.coyote.AbstractProtocol init
      資訊: Initializing ProtocolHandler ["ajp-bio-8010"]
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.Catalina load
      資訊: Initialization processed in 444 ms
      八月 27, 2015 5:14:11 下午 bitronix.tm.integration.tomcat55.BTMLifecycleListener lifecycleEvent
      資訊: Starting Bitronix Transaction Manager
      八月 27, 2015 5:14:11 下午 bitronix.tm.BitronixTransactionManager logVersion
      資訊: Bitronix Transaction Manager version 2.1.4
      八月 27, 2015 5:14:11 下午 bitronix.tm.Configuration buildServerIdArray
      警告: cannot get this JVM unique ID. Make sure it is configured and you only use ASCII characters. Will use IP address instead (unsafe for production usage!).
      八月 27, 2015 5:14:11 下午 bitronix.tm.Configuration buildServerIdArray
      資訊: JVM unique ID: <127.0.0.1>
      八月 27, 2015 5:14:11 下午 bitronix.tm.recovery.Recoverer run
      資訊: recovery committed 0 dangling transaction(s) and rolled back 0 aborted transaction(s) on 0 resource(s) [] (restricted to serverId '127.0.0.1')
      八月 27, 2015 5:14:11 下午 org.apache.catalina.core.StandardService startInternal
      資訊: Starting service Catalina
      八月 27, 2015 5:14:11 下午 org.apache.catalina.core.StandardEngine startInternal
      資訊: Starting Servlet Engine: Apache Tomcat/7.0.64
      八月 27, 2015 5:14:11 下午 org.apache.catalina.startup.HostConfig deployDescriptor
      資訊: Deploying configuration descriptor /usr/local/tomcat7-2/conf/Catalina/localhost/rewards-basic.xml
      八月 27, 2015 5:14:11 下午 org.apache.catalina.loader.WebappClassLoader validateJarFile
      資訊: validateJarFile(/home/syscom/jbpm-6-examples/rewards-basic/target/rewards-basic-6.2.0-SNAPSHOT/WEB-INF/lib/jboss-el-api_2.2_spec-1.0.4.Final.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/el/Expression.class
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.TldConfig execute
      資訊: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.HostConfig deployDescriptor
      資訊: Deployment of configuration descriptor /usr/local/tomcat7-2/conf/Catalina/localhost/rewards-basic.xml has finished in 2,074 ms
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.HostConfig deployDirectory
      資訊: Deploying web application directory /usr/local/tomcat7-2/webapps/host-manager
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.TldConfig execute
      資訊: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.HostConfig deployDirectory
      資訊: Deployment of web application directory /usr/local/tomcat7-2/webapps/host-manager has finished in 73 ms
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.HostConfig deployDirectory
      資訊: Deploying web application directory /usr/local/tomcat7-2/webapps/docs
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.TldConfig execute
      資訊: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.HostConfig deployDirectory
      資訊: Deployment of web application directory /usr/local/tomcat7-2/webapps/docs has finished in 68 ms
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.HostConfig deployDirectory
      資訊: Deploying web application directory /usr/local/tomcat7-2/webapps/manager
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.TldConfig execute
      資訊: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.HostConfig deployDirectory
      資訊: Deployment of web application directory /usr/local/tomcat7-2/webapps/manager has finished in 72 ms
      八月 27, 2015 5:14:13 下午 org.apache.coyote.AbstractProtocol start
      資訊: Starting ProtocolHandler ["http-bio-8087"]
      八月 27, 2015 5:14:13 下午 org.apache.coyote.AbstractProtocol start
      資訊: Starting ProtocolHandler ["ajp-bio-8010"]
      八月 27, 2015 5:14:13 下午 org.apache.catalina.startup.Catalina start
      資訊: Server startup in 2382 ms
      八月 27, 2015 5:14:15 下午 org.apache.catalina.startup.HostConfig undeploy
      資訊: Undeploying context [/rewards-basic]
      八月 27, 2015 5:14:15 下午 org.apache.catalina.startup.HostConfig deployDescriptor
      資訊: Deploying configuration descriptor /usr/local/tomcat7-2/conf/Catalina/localhost/rewards-basic.xml
      八月 27, 2015 5:14:15 下午 org.apache.catalina.loader.WebappClassLoader validateJarFile
      資訊: validateJarFile(/home/syscom/jbpm-6-examples/rewards-basic/target/rewards-basic-6.2.0-SNAPSHOT/WEB-INF/lib/jboss-el-api_2.2_spec-1.0.4.Final.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/el/Expression.class
      八月 27, 2015 5:14:16 下午 org.apache.catalina.startup.TldConfig execute
      資訊: At least one JAR was scanned for TLDs yet contained no TLDs. Enable debug logging for this logger for a complete list of JARs that were scanned but no TLDs were found in them. Skipping unneeded JARs during scanning can improve startup time and JSP compilation time.
      八月 27, 2015 5:14:16 下午 org.apache.catalina.startup.HostConfig deployDescriptor
      資訊: Deployment of configuration descriptor /usr/local/tomcat7-2/conf/Catalina/localhost/rewards-basic.xml has finished in 1,224 ms
      八月 27, 2015 5:14:16 下午 org.apache.catalina.util.LifecycleBase start
      資訊: The start() method was called on component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/rewards-basic]] after start() had already been called. The second call will be ignored.