V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
palmers
V2EX  ›  程序员

有一个问题麻烦大家给点思路,我是在是无从下手了。详情如下:

  •  
  •   palmers · 2015-12-24 15:40:51 +08:00 · 2047 次点击
    这是一个创建于 3258 天前的主题,其中的信息可能已经有所发展或是发生改变。

    生产生一个存储过程查询产生的错误如下(这个问题无法复现,偶尔在生产上出现),以下是前面部分信息.:

    2015-12-23 10:51:59.853 ERROR org.hibernate.transaction.JDBCTransaction - JDBC rollback failed
    java.sql.SQLException: 违反协议: [32]
        at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:464) ~[ojdbc-5.jar:11.2.0.3.0]
        at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:192) ~[ojdbc-5.jar:11.2.0.3.0]
        at oracle.jdbc.driver.T4C7Ocommoncall.doOROLLBACK(T4C7Ocommoncall.java:68) ~[ojdbc-5.jar:11.2.0.3.0]
        at oracle.jdbc.driver.T4CConnection.doRollback(T4CConnection.java:694) ~[ojdbc-5.jar:11.2.0.3.0]
        at oracle.jdbc.driver.PhysicalConnection.rollback(PhysicalConnection.java:3943) ~[ojdbc-5.jar:11.2.0.3.0]
        at weblogic.jdbc.wrapper.PoolConnection_oracle_jdbc_driver_T4CConnection.rollback(Unknown Source) ~[com.bea.core.utils.wrapper_1.4.0.0.jar:1.10.0.0]
        at org.hibernate.transaction.JDBCTransaction.rollbackAndResetAutoCommit(JDBCTransaction.java:213) ~[hibernate-core-3.6.10.Final.jar:3.6.10.Final]
        at org.hibernate.transaction.JDBCTransaction.rollback(JDBCTransaction.java:192) ~[hibernate-core-3.6.10.Final.jar:3.6.10.Final]
        at org.hibernate.ejb.TransactionImpl.rollback(TransactionImpl.java:107) ~[hibernate-entitymanager-3.6.10.Final.jar:3.6.10.Final]
        at org.springframework.orm.jpa.JpaTransactionManager.doRollback(JpaTransactionManager.java:539) [spring-orm-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at org.springframework.transaction.support.AbstractPlatformTransactionManager.processRollback(AbstractPlatformTransactionManager.java:845) [spring-tx-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at org.springframework.transaction.support.AbstractPlatformTransactionManager.rollback(AbstractPlatformTransactionManager.java:822) [spring-tx-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at org.springframework.transaction.interceptor.TransactionAspectSupport.completeTransactionAfterThrowing(TransactionAspectSupport.java:411) [spring-tx-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:114) [spring-tx-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172) [spring-aop-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at org.springframework.dao.support.PersistenceExceptionTranslationInterceptor.invoke(PersistenceExceptionTranslationInterceptor.java:155) [spring-tx-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172) [spring-aop-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at org.springframework.data.jpa.repository.support.LockModeRepositoryPostProcessor$LockModePopulatingMethodIntercceptor.invoke(LockModeRepositoryPostProcessor.java:84) [spring-data-jpa-1.1.0.RELEASE.jar:na]
        at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172) [spring-aop-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:90) [spring-aop-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172) [spring-aop-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202) [spring-aop-3.1.1.RELEASE.jar:3.1.1.RELEASE]
        at $Proxy358.newFindCoefficientById(Unknown Source) [na:na]
    

    newFindCoefficientById 是存储过程调用方法。该方法被调用处的结构如下:

    @Transactional(propagation = Propagation.NOT_SUPPORTED,value = "transactionManager")
    public void foo() {
        newFindCoefficientById(xxx) ;
    }
    

    从以上异常信息中,如果大家能看出点什么,一定请大家给个建议!在此感激不尽!

    8 条回复    2015-12-25 15:22:16 +08:00
    angelface
        1
    angelface  
       2015-12-24 15:47:33 +08:00
    看几个点吧:
    有没有发过新版本最近?如果有, jdbc 驱动有没有动过(升级?或降级?),或是别人不小心引入了新的 jar 包。如果没有, 看 Oracle 是否动过(升级?)
    palmers
        2
    palmers  
    OP
       2015-12-24 18:51:00 +08:00
    @angelface 这些都没有 , 如果有,应该能随时复现这个问题吧?
    woai110120130
        3
    woai110120130  
       2015-12-24 23:51:36 +08:00 via Android
    看看协议 32 是啥么
    palmers
        4
    palmers  
    OP
       2015-12-25 10:53:40 +08:00
    @woai110120130 这个`违反协议[32]` 是 oracle 驱动抛出的是吗?
    Stile
        5
    Stile  
       2015-12-25 11:49:01 +08:00
    1.重启看看
    2.检查驱动
    3.缓存设置为 0
    外行,哈哈
    denghongcai
        6
    denghongcai  
       2015-12-25 14:43:56 +08:00
    palmers
        7
    palmers  
    OP
       2015-12-25 15:21:34 +08:00
    @Stile 重启就会好了
    palmers
        8
    palmers  
    OP
       2015-12-25 15:22:16 +08:00
    @denghongcai 这个我搜索到 检查了 情况不一样, 谢谢了
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   3596 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 04:55 · PVG 12:55 · LAX 20:55 · JFK 23:55
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.