[jboss-user] [JBoss jBPM] - Re: JBoss + JBPM + Mysql - Deployment is not going through
jitendrasupe
do-not-reply at jboss.com
Thu Aug 23 23:57:10 EDT 2007
I was getting this error due to not configureing mySQL DB properly.
I have followed following steps and configure it.
1. Install the MySQL JDBC driver in the $JBOSS_HOME/server/default/lib directory. See also ¬¬¬¬¬SetUpAMysqlDatasource.
2. Delete $JBOSS_HOME/server/default/deploy/hsqldb-ds.xml.
3. Copy $JBOSS_HOME/docs/examples/jca/mysql-ds.xml to $JBOSS_HOME/server/default/deploy. Modify the <local-tx-datasource> element with your MySQL connection settings:
<connection-url>jdbc:mysql://your-hostname:your-port/your-database-name</connection-url>
<driver-class>com.mysql.jdbc.Driver</driver-class>
<user-name>your-user</user-name>
your-pass
4. In $JBOSS_HOME/server/default/conf/standardjaws.xml change the <type-mapping> element:
<type-mapping>mySQL</type-mapping>
5. In standardjbosscmp-jdbc.xml change the following, not necessarily contiguous, elements:
java:/DefaultDS
<datasource-mapping>mySQL</datasource-mapping>
<fk-constraint>true</fk-constraint>
6. Add the following within the element of login-config.xml:
<application-policy name = "MySqlDbRealm?">
<login-module code = "org.jboss.resource.security.ConfiguredIdentityLoginModule?" flag = "required">
<module-option name = "principal">your-user</module-option>
<module-option name = "userName">your-user</module-option>
<module-option name ="password">your-pass</module-option>
<module-option name = "managedConnectionFactoryName">jboss.jca:service=LocalTxCM?,name=DefaultDS</module-option>
</login-module>
</application-policy>
7. Replace file $JBOSS_HOME/server/default/deploy/jms/hsql-jdbc2-service.xml by file $JBOSS_HOME/docs/examples/jms/mysql-jdbc2-service.xml
8. Change MySqlDS? to DefaultDS in $JBOSS_HOME/server/default/deploy/jms/mysql-jdbc2-service.xml:
<depends optional-attribute-name="ConnectionManager">jboss.jca:service=DataSourceBinding,name=DefaultDS
...
9. Rename hsqldb-jdbc-state-service.xml to mysql-jdbc-state-service.xml.
Following Insert statements need to execute on the sample schema to populate appropriate data into required tables:
Also we need to explicitly add contents in JBPM repository for sample examples. Queries for same are available in the folder "jbpm-jpdl-suite-3.2.1\jbpm-jpdl-3.2.1\server\server\jbpm\data\hypersonic\jbpmDB.script" for hypersoninc db. You can migrate those to mySQL DB.
Let me know in case anyone want help regarding this.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4077608#4077608
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4077608
More information about the jboss-user
mailing list