Reputation: 82
I am new in Moqui and I start learning it so in first step I need configure MySQL database so I read the document in Moqui website and write below code in dev config but the error happen
Error initializing webapp context: java.lang.ClassNotFoundException: Class [com.mysql.jdbc.jdbc2.optional.MysqlXADataSource] not found
Do you know what should I do to solve this problem?
<datasource group-name="transactional" database-conf-name="mysql" schema-name="">
<inline-jdbc><xa-properties user="root" password="" pinGlobalTxToPhysicalConnection="true" serverName="127.0.0.1" port="3306" databaseName="MM" autoReconnectForPools="true" useUnicode="true" encoding="UTF-8"/></inline-jdbc>
</datasource>
Upvotes: 0
Views: 175
Reputation: 1
u can try this solution.It will work for you.
<!-- add datasource elements here to configure databases -->
<datasource group-name="transactional" database-conf-name="mysql" schema-name="">
<inline-jdbc jdbc-uri="jdbc:mysql://127.0.0.1:3306/database-name?useSSL=false&autoReconnect=true&useUnicode=true&characterEncoding=UTF-8"
jdbc-username="root" jdbc-password="password" pool-minsize="20" pool-maxsize="50"/>
Upvotes: 0
Reputation: 63
Hi mahdi you can use this config
<datasource group-name="transactional" database-conf-name="mysql" schema-name="db_name" runtime-add-missing="false" startup-add-missing="true">
<inline-jdbc jdbc-uri="jdbc:mysql://127.0.0.1:3306/db_name?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8" jdbc-username="root" jdbc-password="MySqlServerPassword" pool-minsize="2" pool-maxsize="50"/>
</datasource>
Upvotes: 1