开发者

How to make a readonly xa datasource connection to mysql server on jboss

开发者 https://www.devze.com 2023-02-24 09:41 出处:网络
it is clear in the title, I would be great if you share your experience about it. I tried that but didn\'t work..

it is clear in the title, I would be great if you share your experience about it.

I tried that but didn't work..

...
    <xa-datasource>    
    <jndi-name>DSReadOnly</jndi-name>
    <xa-datasource-clas开发者_JAVA百科s>com.mysql.jdbc.jdbc2.optional.MysqlXADataSource</xa-datasource-class> 
    .
    ..
    <xa-datasource-property name="readOnly">true</xa-datasource-property>
     ..
     .

</xa-datasource>


You should define access privileges on the database level, not in datasource.


According to Mysql documentation there is no such properties like readOnly:

Driver/Datasource Class Names, URL Syntax and Configuration Properties for Connector/J

And also I cannot find any information about such properties in Mysql JDBC Driver. You can check sources for properties interface here: ConnectionProperties.

0

精彩评论

暂无评论...
验证码 换一张
取 消