This site contains the documentation that is relevant to older WSO2 product versions and offerings.
For the latest WSO2 documentation, visit https://wso2.com/documentation/.
Configuring MSSQL
To configure and run MSSQL as your RDBMS, you must do the following.
- Open theÂ
<MB_HOME>/repository/conf/datasources/master-datasources.xml
 file. This is where datasources are configured to point to the databases used by the Message Broker. This file consists of commented out configurations for datasources. The datasource configuration for MSSQL is among these. The changes made to this file must be done in both broker nodes. Uncomment or add the following configuration into the master-datasources.xml file. Update the JDBC URL to correctly point to your database and enter the username and password for a MSSQL database user with the proper permissions.
<datasource> <name>WSO2_MB_STORE_DB</name> <jndiConfig> <name>jdbc/MSSQLWSO2MBStoreDB</name> </jndiConfig> <definition type="RDBMS"> <configuration> <defaultAutoCommit>false</defaultAutoCommit> <dataSourceClassName>com.microsoft.sqlserver.jdbc.SQLServerXADataSource</dataSourceClassName> <dataSourceProps> <property name = "URL">jdbc:sqlserver://127.0.0.1\SQLExpress</property> <property name="databaseName">wso2mb</property> <property name="user">sa</property> <property name="password">mssql</property> </dataSourceProps> </configuration> </definition> </datasource>
Â
- Open theÂ
<MB_HOME>/repository/conf/broker.xml
 file. This is the root configuration file of Message Broker. The changes made to this file must be done in all the WSO2 Message Broker nodes. In the broker.xml file we need to use the MSSQL message store and Andes context store. To do this, uncomment or add the following configuration.
... <persistence> <messageStore class="org.wso2.andes.store.rdbms.RDBMSMessageStoreImpl"> <property name="dataSource">jdbc/MSSQLWSO2MBStoreDB</property> </messageStore> <andesContextStore class="org.wso2.andes.store.rdbms.RDBMSAndesContextStoreImpl"> <property name="dataSource">jdbc/MSSQLWSO2MBStoreDB</property> </andesContextStore> ... </persistence>