spring2.5,ibatis2.3 oracle11g只读事物不能生效

开发环境:spring2.5,ibatis2.3 oracle11g
执行一个get的service的方法时,日志里中显示设置了connection为readonly,但还是能写入数据库。
怎么才能让readonly的方法不能写入数据库呢,或者说怎么实现这个只读事物呢。
[code="java"]<?xml version="1.0" encoding="UTF-8"?>
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:tx="http://www.springframework.org/schema/tx"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.5.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.5.xsd" >

<!--该配置文件主要用于管理项目中的事务 -->








<aop:config>
    <aop:pointcut id="taxService"
        expression="execution(* bj.n22..service.*.*(..))" />
    <aop:advisor advice-ref="txAdvice" pointcut-ref="taxService" />
</aop:config>

<tx:advice id="txAdvice" transaction-manager="transactionManager">
    <tx:attributes>
        <tx:method name="save*" />
        <tx:method name="delete*" />
        <tx:method name="update*" />
        <tx:method name="new*" propagation="REQUIRES_NEW" />
        <tx:method name="*" read-only="true" />
    </tx:attributes>
</tx:advice>

<bean id="dataSource" class="com.mchange.v2.c3p0.ComboPooledDataSource" destroy-method="close">   
<property name="driverClass" value="oracle.jdbc.driver.OracleDriver"/>   
<property name="jdbcUrl" value="jdbc:oracle:thin:@192.168.1.251:1521:orcl"/>   
<property name="user" value="demo"></property>   
<property name="password" value="demo" />   
<property name="minPoolSize" value="1" />   
<property name="maxPoolSize" value="1" />   
<property name="maxIdleTime" value="1800" />   
<property name="acquireIncrement" value="2" />   
<property name="maxStatements" value="0" />   
<property name="initialPoolSize" value="1" />   
<property name="idleConnectionTestPeriod" value="1800" />   
<property name="acquireRetryAttempts" value="30" />   
<property name="breakAfterAcquireFailure" value="true" />   
<property name="testConnectionOnCheckout" value="false" />
<property name="preferredTestQuery" value="select * from dual" /> 
</bean>           


    <!--根据dataSource和configLocation创建一个SqlMapClient-->
<bean id="sqlMapClient" class="org.springframework.orm.ibatis.SqlMapClientFactoryBean">
    <property name="configLocation">
        <value>/WEB-INF/classes/spring/sqlMapConfig.xml</value>
    </property>
    <property name="dataSource">
        <ref bean="dataSource"/>
    </property>
</bean>

<!--将上面的模版类织入到我们的DAO对象中-->
<bean id="baseDao" class="bj.n22.base.dao.BaseDaoImpl" >
    <property name="sqlMapClient">
        <ref bean="sqlMapClient" />
    </property>
</bean>

 <import resource="application-log.xml"/>

[/code]

日志输出:
DEBUG [com.opensymphony.xwork2.util.InstantiatingNullHandler:72] Entering nullPropertyValue [target=[com.opensymphony.xwork2.DefaultTextProvider@14b0c98], property=struts]
DEBUG [com.opensymphony.xwork2.DefaultActionProxy:65] Creating an DefaultActionProxy for namespace /log/log and action name edit
DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory:389] No bean named 'bj.n22.rms.log.action.LogAction' found in org.springframework.beans.factory.support.DefaultListableBeanFactory@103bc02: defining beans [dataSource,transactionManager,org.springframework.aop.config.internalAutoProxyCreator,taxService,org.springframework.aop.support.DefaultBeanFactoryPointcutAdvisor#0,txAdvice,sqlMapClient,baseDao,logDao,logService]; root of factory hierarchy
DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory:1071] Not autowiring property 'actionErrors' of bean 'bj.n22.rms.log.action.LogAction' by name: no matching bean found
DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory:1071] Not autowiring property 'actionMessages' of bean 'bj.n22.rms.log.action.LogAction' by name: no matching bean found
DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory:1071] Not autowiring property 'fieldErrors' of bean 'bj.n22.rms.log.action.LogAction' by name: no matching bean found
DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory:203] Returning cached instance of singleton bean 'logService'
DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory:1065] Added autowiring by name from bean name 'bj.n22.rms.log.action.LogAction' via property 'logService' to bean named 'logService'
DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory:1071] Not autowiring property 'servletRequest' of bean 'bj.n22.rms.log.action.LogAction' by name: no matching bean found
DEBUG [com.opensymphony.xwork2.interceptor.PrefixMethodInvocationUtil:141] cannot find method [prepareEdit] in action [bj.n22.rms.log.action.LogAction@296cf1]
DEBUG [com.opensymphony.xwork2.interceptor.PrefixMethodInvocationUtil:141] cannot find method [prepareDoEdit] in action [bj.n22.rms.log.action.LogAction@296cf1]
DEBUG [com.opensymphony.xwork2.interceptor.I18nInterceptor:97] intercept '/log/log/edit' {
DEBUG [com.opensymphony.xwork2.interceptor.I18nInterceptor:110] requested_locale=null
DEBUG [com.opensymphony.xwork2.interceptor.I18nInterceptor:140] before Locale=zh_CN
DEBUG [com.opensymphony.xwork2.util.InstantiatingNullHandler:72] Entering nullPropertyValue [target=[bj.n22.rms.log.vo.Log@1cb150a, bj.n22.rms.log.action.LogAction@296cf1, com.opensymphony.xwork2.DefaultTextProvider@14b0c98], property=struts]
DEBUG [org.apache.struts2.interceptor.FileUploadInterceptor:204] Bypassing /log/log/ edit
DEBUG [com.opensymphony.xwork2.interceptor.StaticParametersInterceptor:83] Setting static parameters {}
DEBUG [com.opensymphony.xwork2.interceptor.ParametersInterceptor:148] Setting params logId => [ 1 ]
DEBUG [com.opensymphony.xwork2.util.XWorkConverter:388] Property: logId
DEBUG [com.opensymphony.xwork2.util.XWorkConverter:389] Class: bj.n22.rms.log.vo.Log
DEBUG [com.opensymphony.xwork2.util.XWorkConverter:404] converter is null for property logId. Mapping size: 0
DEBUG [com.opensymphony.xwork2.util.XWorkConverter:278] field-level type converter for property [logId] = none found
DEBUG [com.opensymphony.xwork2.util.XWorkConverter:302] global-level type converter for property [logId] = none found
DEBUG [com.opensymphony.xwork2.util.XWorkConverter:320] falling back to default type converter [com.opensymphony.xwork2.util.XWorkBasicConverter@1470933]
DEBUG [org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor:134] Validating /log/log/edit with method edit.
DEBUG [com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor:183] Invoking validate() on action bj.n22.rms.log.action.LogAction@296cf1
DEBUG [com.opensymphony.xwork2.interceptor.PrefixMethodInvocationUtil:141] cannot find method [validateEdit] in action [bj.n22.rms.log.action.LogAction@296cf1]
DEBUG [com.opensymphony.xwork2.interceptor.PrefixMethodInvocationUtil:141] cannot find method [validateDoEdit] in action [bj.n22.rms.log.action.LogAction@296cf1]
DEBUG [com.opensymphony.xwork2.DefaultActionInvocation:383] Executing action method = edit
DEBUG [org.springframework.jdbc.datasource.DataSourceTransactionManager:319] Using transaction object [org.springframework.jdbc.datasource.DataSourceTransactionManager$DataSourceTransactionObject@1714bf9]
DEBUG [org.springframework.jdbc.datasource.DataSourceTransactionManager:347] Creating new transaction with name [bj.n22.rms.log.service.LogService.get]: PROPAGATION_REQUIRED,ISOLATION_DEFAULT,readOnly
DEBUG [com.mchange.v2.resourcepool.BasicResourcePool:1644] trace com.mchange.v2.resourcepool.BasicResourcePool@1368553 managed: 1, unused: 0, excluded: 0
DEBUG [org.springframework.jdbc.datasource.DataSourceTransactionManager:202] Acquired Connection [com.mchange.v2.c3p0.impl.NewProxyConnection@bbce54] for JDBC transaction
DEBUG [org.springframework.jdbc.datasource.DataSourceUtils:155] Setting JDBC Connection [com.mchange.v2.c3p0.impl.NewProxyConnection@bbce54] read-only
DEBUG [org.springframework.jdbc.datasource.DataSourceTransactionManager:219] Switching JDBC Connection [com.mchange.v2.c3p0.impl.NewProxyConnection@bbce54] to manual commit
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:168] Bound value [org.springframework.jdbc.datasource.ConnectionHolder@1e701b0] for key [com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge15c8e1rol9i71bnat25|9a1621, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> oracle.jdbc.driver.OracleDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge15c8e1rol9i71bnat25|9a1621, idleConnectionTestPeriod -> 1800, initialPoolSize -> 1, jdbcUrl -> jdbc:oracle:thin:@192.168.1.251:1521:orcl, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 1, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> select * from dual, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]] to thread [http-8777-1]
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:222] Initializing transaction synchronization
DEBUG [org.springframework.transaction.interceptor.TransactionInterceptor:288] Getting transaction for [bj.n22.rms.log.service.LogService.get]
DEBUG [org.springframework.orm.ibatis.SqlMapClientTemplate:177] Opened SqlMapSession [com.ibatis.sqlmap.engine.impl.SqlMapSessionImpl@d6999b] for iBATIS operation
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:140] Retrieved value [org.springframework.jdbc.datasource.ConnectionHolder@1e701b0] for key [com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge15c8e1rol9i71bnat25|9a1621, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> oracle.jdbc.driver.OracleDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge15c8e1rol9i71bnat25|9a1621, idleConnectionTestPeriod -> 1800, initialPoolSize -> 1, jdbcUrl -> jdbc:oracle:thin:@192.168.1.251:1521:orcl, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 1, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> select * from dual, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]] bound to thread [http-8777-1]
DEBUG [java.sql.Connection:27] {conn-100012} Connection
DEBUG [org.springframework.orm.ibatis.SqlMapClientTemplate:194] Obtained JDBC Connection [Transaction-aware proxy for target Connection [com.mchange.v2.c3p0.impl.NewProxyConnection@bbce54]] for iBATIS operation
DEBUG [java.sql.Connection:27] {conn-100012} Preparing Statement: select SEQ_PRIMARY.NEXTVAL from dual
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:140] Retrieved value [org.springframework.jdbc.datasource.ConnectionHolder@1e701b0] for key [com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge15c8e1rol9i71bnat25|9a1621, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> oracle.jdbc.driver.OracleDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge15c8e1rol9i71bnat25|9a1621, idleConnectionTestPeriod -> 1800, initialPoolSize -> 1, jdbcUrl -> jdbc:oracle:thin:@192.168.1.251:1521:orcl, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 1, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> select * from dual, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]] bound to thread [http-8777-1]
DEBUG [java.sql.PreparedStatement:27] {pstm-100013} Executing Statement: select SEQ_PRIMARY.NEXTVAL from dual
DEBUG [java.sql.PreparedStatement:27] {pstm-100013} Parameters: []
DEBUG [java.sql.PreparedStatement:27] {pstm-100013} Types: []
DEBUG [java.sql.ResultSet:27] {rset-100014} ResultSet
DEBUG [java.sql.ResultSet:27] {rset-100014} Header: [NEXTVAL]
DEBUG [java.sql.ResultSet:27] {rset-100014} Result: [21]
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:140] Retrieved value [org.springframework.jdbc.datasource.ConnectionHolder@1e701b0] for key [com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge15c8e1rol9i71bnat25|9a1621, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> oracle.jdbc.driver.OracleDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge15c8e1rol9i71bnat25|9a1621, idleConnectionTestPeriod -> 1800, initialPoolSize -> 1, jdbcUrl -> jdbc:oracle:thin:@192.168.1.251:1521:orcl, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 1, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> select * from dual, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]] bound to thread [http-8777-1]
DEBUG [org.springframework.orm.ibatis.SqlMapClientTemplate:177] Opened SqlMapSession [com.ibatis.sqlmap.engine.impl.SqlMapSessionImpl@178d7b4] for iBATIS operation
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:140] Retrieved value [org.springframework.jdbc.datasource.ConnectionHolder@1e701b0] for key [com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge15c8e1rol9i71bnat25|9a1621, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> oracle.jdbc.driver.OracleDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge15c8e1rol9i71bnat25|9a1621, idleConnectionTestPeriod -> 1800, initialPoolSize -> 1, jdbcUrl -> jdbc:oracle:thin:@192.168.1.251:1521:orcl, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 1, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> select * from dual, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]] bound to thread [http-8777-1]
DEBUG [java.sql.Connection:27] {conn-100015} Connection
DEBUG [org.springframework.orm.ibatis.SqlMapClientTemplate:194] Obtained JDBC Connection [Transaction-aware proxy for target Connection [com.mchange.v2.c3p0.impl.NewProxyConnection@bbce54]] for iBATIS operation
DEBUG [java.sql.Connection:27] {conn-100015} Preparing Statement: insert into TEST_LOG (logid,username,logTime) values (?,?,?)
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:140] Retrieved value [org.springframework.jdbc.datasource.ConnectionHolder@1e701b0] for key [com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge15c8e1rol9i71bnat25|9a1621, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> oracle.jdbc.driver.OracleDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge15c8e1rol9i71bnat25|9a1621, idleConnectionTestPeriod -> 1800, initialPoolSize -> 1, jdbcUrl -> jdbc:oracle:thin:@192.168.1.251:1521:orcl, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 1, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> select * from dual, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]] bound to thread [http-8777-1]
DEBUG [java.sql.PreparedStatement:27] {pstm-100016} Executing Statement: insert into TEST_LOG (logid,username,logTime) values (?,?,?)
DEBUG [java.sql.PreparedStatement:27] {pstm-100016} Parameters: [21, get, null]
DEBUG [java.sql.PreparedStatement:27] {pstm-100016} Types: [java.lang.Long, java.lang.String, null]
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:140] Retrieved value [org.springframework.jdbc.datasource.ConnectionHolder@1e701b0] for key [com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge15c8e1rol9i71bnat25|9a1621, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> oracle.jdbc.driver.OracleDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge15c8e1rol9i71bnat25|9a1621, idleConnectionTestPeriod -> 1800, initialPoolSize -> 1, jdbcUrl -> jdbc:oracle:thin:@192.168.1.251:1521:orcl, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 1, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> select * from dual, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]] bound to thread [http-8777-1]
DEBUG [org.springframework.orm.ibatis.SqlMapClientTemplate:177] Opened SqlMapSession [com.ibatis.sqlmap.engine.impl.SqlMapSessionImpl@17b4650] for iBATIS operation
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:140] Retrieved value [org.springframework.jdbc.datasource.ConnectionHolder@1e701b0] for key [com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge15c8e1rol9i71bnat25|9a1621, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> oracle.jdbc.driver.OracleDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge15c8e1rol9i71bnat25|9a1621, idleConnectionTestPeriod -> 1800, initialPoolSize -> 1, jdbcUrl -> jdbc:oracle:thin:@192.168.1.251:1521:orcl, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 1, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> select * from dual, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]] bound to thread [http-8777-1]
DEBUG [java.sql.Connection:27] {conn-100017} Connection
DEBUG [org.springframework.orm.ibatis.SqlMapClientTemplate:194] Obtained JDBC Connection [Transaction-aware proxy for target Connection [com.mchange.v2.c3p0.impl.NewProxyConnection@bbce54]] for iBATIS operation
DEBUG [java.sql.Connection:27] {conn-100017} Preparing Statement: select * from TEST_LOG where logid=?
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:140] Retrieved value [org.springframework.jdbc.datasource.ConnectionHolder@1e701b0] for key [com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge15c8e1rol9i71bnat25|9a1621, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> oracle.jdbc.driver.OracleDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge15c8e1rol9i71bnat25|9a1621, idleConnectionTestPeriod -> 1800, initialPoolSize -> 1, jdbcUrl -> jdbc:oracle:thin:@192.168.1.251:1521:orcl, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 1, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> select * from dual, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]] bound to thread [http-8777-1]
DEBUG [java.sql.PreparedStatement:27] {pstm-100018} Executing Statement: select * from TEST_LOG where logid=?
DEBUG [java.sql.PreparedStatement:27] {pstm-100018} Parameters: [1]
DEBUG [java.sql.PreparedStatement:27] {pstm-100018} Types: [java.lang.Long]
DEBUG [java.sql.ResultSet:27] {rset-100019} ResultSet
DEBUG [java.sql.ResultSet:27] {rset-100019} Header: [LOGID, USERNAME, LOGTIME]
DEBUG [java.sql.ResultSet:27] {rset-100019} Result: [1, 测试new事物, null]
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:140] Retrieved value [org.springframework.jdbc.datasource.ConnectionHolder@1e701b0] for key [com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge15c8e1rol9i71bnat25|9a1621, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> oracle.jdbc.driver.OracleDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge15c8e1rol9i71bnat25|9a1621, idleConnectionTestPeriod -> 1800, initialPoolSize -> 1, jdbcUrl -> jdbc:oracle:thin:@192.168.1.251:1521:orcl, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 1, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> select * from dual, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]] bound to thread [http-8777-1]
DEBUG [org.springframework.transaction.interceptor.TransactionInterceptor:317] Completing transaction for [bj.n22.rms.log.service.LogService.get]
DEBUG [org.springframework.jdbc.datasource.DataSourceTransactionManager:833] Triggering beforeCommit synchronization
DEBUG [org.springframework.jdbc.datasource.DataSourceTransactionManager:846] Triggering beforeCompletion synchronization
DEBUG [org.springframework.jdbc.datasource.DataSourceTransactionManager:660] Initiating transaction commit
DEBUG [org.springframework.jdbc.datasource.DataSourceTransactionManager:259] Committing JDBC transaction on Connection [com.mchange.v2.c3p0.impl.NewProxyConnection@bbce54]
DEBUG [org.springframework.jdbc.datasource.DataSourceTransactionManager:859] Triggering afterCommit synchronization
DEBUG [org.springframework.jdbc.datasource.DataSourceTransactionManager:875] Triggering afterCompletion synchronization
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:276] Clearing transaction synchronization
DEBUG [org.springframework.transaction.support.TransactionSynchronizationManager:193] Removed value [org.springframework.jdbc.datasource.ConnectionHolder@1e701b0] for key [com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 2, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> true, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hge15c8e1rol9i71bnat25|9a1621, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> oracle.jdbc.driver.OracleDriver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hge15c8e1rol9i71bnat25|9a1621, idleConnectionTestPeriod -> 1800, initialPoolSize -> 1, jdbcUrl -> jdbc:oracle:thin:@192.168.1.251:1521:orcl, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 1800, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 1, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> select * from dual, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]] from thread [http-8777-1]
DEBUG [org.springframework.jdbc.datasource.DataSourceUtils:202] Resetting read-only flag of JDBC Connection [com.mchange.v2.c3p0.impl.NewProxyConnection@bbce54]
DEBUG [org.springframework.jdbc.datasource.DataSourceTransactionManager:314] Releasing JDBC Connection [com.mchange.v2.c3p0.impl.NewProxyConnection@bbce54] after transaction
DEBUG [org.springframework.jdbc.datasource.DataSourceUtils:312] Returning JDBC Connection to DataSource
DEBUG [com.mchange.v2.resourcepool.BasicResourcePool:1644] trace com.mchange.v2.resourcepool.BasicResourcePool@1368553 managed: 1, unused: 0, excluded: 0
DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory:389] No bean named 'org.apache.struts2.dispatcher.VelocityResult' found in org.springframework.beans.factory.support.DefaultListableBeanFactory@103bc02: defining beans [dataSource,transactionManager,org.springframework.aop.config.internalAutoProxyCreator,taxService,org.springframework.aop.support.DefaultBeanFactoryPointcutAdvisor#0,txAdvice,sqlMapClient,baseDao,logDao,logService]; root of factory hierarchy
DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory:183] Ignoring constructor [public org.apache.struts2.dispatcher.VelocityResult(java.lang.String)] of bean 'org.apache.struts2.dispatcher.VelocityResult': org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'org.apache.struts2.dispatcher.VelocityResult': Unsatisfied dependency expressed through constructor argument with index 0 of type [java.lang.String]: No unique bean of type [java.lang.String] is defined: Unsatisfied dependency of type [class java.lang.String]: expected at least 1 matching bean
DEBUG [org.springframework.beans.factory.support.DefaultListableBeanFactory:1071] Not autowiring property 'velocityManager' of bean 'org.apache.struts2.dispatcher.VelocityResult' by name: no matching bean found
DEBUG [com.opensymphony.xwork2.util.InstantiatingNullHandler:72] Entering nullPropertyValue [target=[bj.n22.rms.log.vo.Log@1cb150a, bj.n22.rms.log.action.LogAction@296cf1, com.opensymphony.xwork2.DefaultTextProvider@14b0c98], property=message]
DEBUG [com.opensymphony.xwork2.util.InstantiatingNullHandler:72] Entering nullPropertyValue [target=[bj.n22.rms.log.vo.Log@1cb150a, bj.n22.rms.log.action.LogAction@296cf1, com.opensymphony.xwork2.DefaultTextProvider@14b0c98], property=message]
DEBUG [com.opensymphony.xwork2.util.InstantiatingNullHandler:72] Entering nullPropertyValue [target=[bj.n22.rms.log.vo.Log@1cb150a, bj.n22.rms.log.action.LogAction@296cf1, com.opensymphony.xwork2.DefaultTextProvider@14b0c98], property=struts_token]
DEBUG [com.opensymphony.xwork2.interceptor.I18nInterceptor:145] after Locale=zh_CN
DEBUG [com.opensymphony.xwork2.interceptor.I18nInterceptor:149] intercept }
DEBUG [com.mchange.v2.resourcepool.BasicResourcePool:1935] Checking for expired resources - Thu Mar 24 10:36:00 CST 2011 [com.mchange.v2.resourcepool.BasicResourcePool@1368553]
DEBUG [com.mchange.v2.resourcepool.BasicResourcePool:1447] BEGIN check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@1368553]
DEBUG [com.mchange.v2.resourcepool.BasicResourcePool:1468] FINISHED check for expired resources. [com.mchange.v2.resourcepool.BasicResourcePool@1368553]

2个回答

嗯,你说的有一定的道理,我也看了一下下面的这个文章
http://webwork.iteye.com/blog/576529

要保证只读,需要设置数据库的用户的权限,这里的只读,只是在保证在事务方面进行优化

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
Spring2.5 ibatis 配置问题
-
昨天弄到半夜,Spring2.5 Ibatis2.3 注解注入,配置事务管理不成功
-
org.apache.ibatis.ognl.OgnlException:怎么解决
-
spring3.1.1+ibatis3.1.1+struts2.2.3框架搭建报错
-
springboot 连接不到oracle
-
org.apache.ibatis.reflection.ReflectionException:
-
org.apache.ibatis.exceptions.PersistenceException怎么解决?
-
创建名为“userRealm”的bean时出错:通过字段“adminService”表示的未满足的依赖关系;嵌套异常是org.springframe .bean .factory
-
spring整合mybatis时,student.java只构建有参构造函数为什么会报如下错误,加了无参构造错误就会消失
-
spring struts2.0 ibatis 服务器启动报错怎么回事?
-
异常org.mybatis.spring.MyBatisSystemException:
-
org.apache.ibatis.io.ResolverUtil
-
spring boot 。Illegal access:。。。 Could not load [mapper/].
-
spring mvc+ibatis+oracle ORA-02289: 序列不存在
-
一个事务里面执行两个insert 语句 只有后面一个insert 被commit,请问大神怎么回事?
-
关于Spring 2.5里面的基于注解的配置的一些疑惑
-
关于struts2 spring ibatis 结合问题
-
spring和mybatis整合的,运行测试代码初始化sqlSessionFactory失败
-
Error querying database. Cause: org.springframework.jdbc.CannotGetJdbcConnectionException: Failed to obtain JDBC Connection
-
程序员实用工具网站
目录 1、搜索引擎 2、PPT 3、图片操作 4、文件共享 5、应届生招聘 6、程序员面试题库 7、办公、开发软件 8、高清图片、视频素材网站 9、项目开源 10、在线工具宝典大全 程序员开发需要具备良好的信息检索能力,为了备忘(收藏夹真是满了),将开发过程中常用的网站进行整理。 1、搜索引擎 1.1、秘迹搜索 一款无敌有良心、无敌安全的搜索引擎,不会收集私人信息,保...
我花了一夜用数据结构给女朋友写个H5走迷宫游戏
起因 又到深夜了,我按照以往在csdn和公众号写着数据结构!这占用了我大量的时间!我的超越妹妹严重缺乏陪伴而 怨气满满! 而女朋友时常埋怨,认为数据结构这么抽象难懂的东西没啥作用,常会问道:天天写这玩意,有啥作用。而我答道:能干事情多了,比如写个迷宫小游戏啥的! 当我码完字准备睡觉时:写不好别睡觉! 分析 如果用数据结构与算法造出东西来呢? ...
别再翻了,面试二叉树看这 11 个就够了~
写在前边 数据结构与算法: 不知道你有没有这种困惑,虽然刷了很多算法题,当我去面试的时候,面试官让你手写一个算法,可能你对此算法很熟悉,知道实现思路,但是总是不知道该在什么地方写,而且很多边界条件想不全面,一紧张,代码写的乱七八糟。如果遇到没有做过的算法题,思路也不知道从何寻找。面试吃了亏之后,我就慢慢的做出总结,开始分类的把数据结构所有的题型和解题思路每周刷题做出的系统性总结写在了 Github...
让程序员崩溃的瞬间(非程序员勿入)
今天给大家带来点快乐,程序员才能看懂。 来源:https://zhuanlan.zhihu.com/p/47066521 1. 公司实习生找 Bug 2.在调试时,将断点设置在错误的位置 3.当我有一个很棒的调试想法时 4.偶然间看到自己多年前写的代码 5.当我第一次启动我的单元测试时 ...
接私活必备的 10 个开源项目!
点击蓝色“GitHubDaily”关注我加个“星标”,每天下午 18:35,带你逛 GitHub!作者 | SevDot来源 | http://1t.click/VE8W...
GitHub开源的10个超棒后台管理面板
目录 1、AdminLTE 2、vue-Element-Admin 3、tabler 4、Gentelella 5、ng2-admin 6、ant-design-pro 7、blur-admin 8、iview-admin 9、material-dashboard 10、layui 项目开发中后台管理平台必不可少,但是从零搭建一套多样化后台管理并不容易,目前有许多开源、免费、...
Git 天天用 但是 Git 原理你了解吗?
Git 原理 做技术一定要知其然知其所以然,意思就是:知道它是这样的,更知道它为什么是这样的。我主要通过4块内容来简单介绍 Git 是原理是什么样的。这4块内容如下: Git 存储目录结构介绍 Git 是如何存储的 Git 的对象 Git引用 当然 Git 原理不仅仅包含这些,想要更深入了解请查看官方教程 https://git-scm.com/book/zh/v2/。 本文内容是我在 Git...
100 个网络基础知识普及,看完成半个网络高手
欢迎添加华为云小助手微信(微信号:HWCloud002或HWCloud003),输入关键字“加群”,加入华为云线上技术讨论群;输入关键字“最新活动”,获取华为云最新特惠促销。华为云诸多技术大咖、特惠活动等你来撩! 1)什么是链接? 链接是指两个设备之间的连接。它包括用于一个设备能够与另一个设备通信的电缆类型和协议。 2)OSI 参考模型的层次是什么? 有 7 个 OSI 层:物理...
漫画:什么是摩尔斯电码?
摩尔斯电码是什么摩尔斯电码(Morse code),是1837年由美国人发明,本质上是一种对信息的编码,最初用于人们的远程通信。那个时候,人们连电话都还没发明出来,更不用...
中国最顶级的一批程序员,从首富到首负!
过去的20年是程序员快意恩仇的江湖时代通过代码,实现梦想和财富有人痴迷于技术,做出一夜成名的产品有人将技术变现,创办企业成功上市这些早一代的程序员们创造的奇迹引发了一浪高...
为什么面向对象糟透了?
又是周末,编程语言“三巨头”Java, Lisp 和C语言在Hello World咖啡馆聚会。服务员送来咖啡的同时还带来了一张今天的报纸, 三人寒暄了几句, C语言翻开了...
分享靠写代码赚钱的一些门路
作者 mezod,译者 josephchang10如今,通过自己的代码去赚钱变得越来越简单,不过对很多人来说依然还是很难,因为他们不知道有哪些门路。今天给大家分享一个精彩...
对计算机专业来说学历真的重要吗?
我本科学校是渣渣二本,研究生学校是985,现在毕业五年,校招笔试、面试,社招面试参加了两年了,就我个人的经历来说下这个问题。 这篇文章很长,但绝对是精华,相信我,读完以后,你会知道学历不好的解决方案,记得帮我点赞哦。 先说结论,无论赞不赞同,它本质就是这样:对于技术类工作而言,学历五年以内非常重要,但有办法弥补。五年以后,不重要。 目录: 张雪峰讲述的事实 我看到的事实 为什么会这样 ...
在线就能用的Linux我给你找好了
来源:公众号【编程珠玑】 作者:守望先生 网站:https://www.yanbinghu.com 前言 是不是不想装虚拟机,还想体验一下Linux?是不是自己的电脑不在,又想搞事情?今天给大家推荐几个在线就可以玩的Linux环境以及学习Shell的地方。 在线Linux环境 如果你不想安装虚拟机,这里提供几个在线就能把玩Linux的网站,他们不需要注册用户,可以直接使用。 Unix...
世界上最好的学习法:费曼学习法
你是否曾幻想读一遍书就记住所有的内容?是否想学习完一项技能就马上达到巅峰水平?除非你是天才,不然这是不可能的。对于大多数的普通人来说,可以通过笨办法(死记硬背)来达到学习的目的,但效率低下。当然,也可以通过优秀的学习法来进行学习,比如今天讲的“费曼学习法”,可以将你的学习效率极大的提高。 费曼学习法是由加拿大物理学家费曼所发明的一种高效的学习方法,费曼本身是一个天才,13岁自学微积分,24岁加入曼...
学Linux到底学什么
来源:公众号【编程珠玑】 作者:守望先生 网站:https://www.yanbinghu.com/2019/09/25/14472.html 前言 ​我们常常听到很多人说要学学Linux或者被人告知说应该学学Linux,那么学Linux到底要学什么? 为什么要学Linux 在回答学什么之前,我们先看看为什么要学。首先我们需要认识到的是,很多服务器使用的是Linux系统,而作为服务器应...
深入理解C语言指针
一、指针的概念 要知道指针的概念,要先了解变量在内存中如何存储的。在存储时,内存被分为一块一块的。每一块都有一个特有的编号。而这个编号可以暂时理解为指针,就像酒店的门牌号一样。 1.1、变量和地址 先写一段简单的代码: void main(){ int x = 10, int y = 20; } 这段代码非常简单,就是两个变量的声明,分别赋值了 10、20。我们把内存当做一个酒店,而每个房间就...
C语言实现推箱子游戏
很早就想过做点小游戏了,但是一直没有机会动手。今天闲来无事,动起手来。过程还是蛮顺利的,代码也不是非常难。今天给大家分享一下~ 一、介绍 开发语言:C语言 开发工具:Dev-C++ 5.11 日期:2019年9月28日 作者:ZackSock 也不说太多多余的话了,先看一下效果图: 游戏中的人物、箱子、墙壁、球都是字符构成的。通过wasd键移动,规则的话就是推箱子的规则,也就不多说了。 二、代...
面试官:兄弟,说说基本类型和包装类型的区别吧
Java 的每个基本类型都对应了一个包装类型,比如说 int 的包装类型为 Integer,double 的包装类型为 Double。基本类型和包装类型的区别主要有以下 4 点。
焦虑的互联网人及35岁定律
一、35岁定律 好像现在整个互联网行业都在贩卖焦虑,从之前的30岁淘汰,到现在的35岁,到最新的39.9岁,你会发现,年龄趋势怎么在上升啊,对了兄弟,就是那一批人嘛,他们每年涨一岁,可不就是焦虑年龄越来越大了。 最早我看到的新闻是说,第一批互联网人都赶上了好时候,现在差不多五十岁左右,要么创业成功,要么在大公司做股东,反正都是实现了经济自由的一波人,包括马老师,都是那一拨。 那剩下的呢?有人...
8000字干货:那些很厉害的人是怎么构建知识体系的
本文约8000字,正常阅读需要15~20分钟。读完本文可以获得如下收益: 分辨知识和知识体系的差别 理解如何用八大问发现知识的连接点; 掌握致用类知识体系的构建方法; 能够应用甜蜜区模型找到特定领域来构建知识体系。 1. 知识体系?有必要吗? 小张准备通过跑步锻炼身体,可因为之前听说过小腿变粗、膝盖受伤、猝死等等与跑步有关的意外状况,有点担心自己会掉进各种坑里,就在微信上问朋友圈一直晒跑步...
相关热词 用户权限才c# c#应用程序实例 c#请求接口数据 c#高效读写plc c#代码规范快捷方式 c#编辑模板 c# 内存存储 c# poi 生成图表 c#页面 弹出页面选择框 c# 不实现 继承接口