`

JBO-25014: RowInconsistentException

 
阅读更多

现象:

在ADF中新建或者更新数据的时候,进行连续的Commit操作,会出现JBO-25014异常

  

异常原因:

在 比较EO Cached Entity与数据库中的值的时候,出现不一致。也就是在ADF的Commit操作后,数据库中的数据被其他操作修改了,这种情况会出现在数据库端使用了 Trigger的时候;另一种情况是,EO中的Attribute使用了用户自定义的domain-type,该类型的equals()方法返回 false

Cause: The database value does not match the cached value for this entity object. This could happen when another user or operation has committed modifications to the same entity-row in the database. This exception can also be thrown if the equals() method on one of the domain-type attributes in the entity fails. 

 

解决方案:

1,如果EO有Attribute使用了domain-type,检查equals()方法;

2,如果数据库端使用了trigger,修改EO的 Refresh after update  属性;

3,使用vo.executeQuery同步Model层与数据库中的数据。

Action: Choose from the following options: 

  

 

Verify that another user or operation has not modified the same row in the database. If this entity has attributes of a domain type verify that the equals() method on these domains do not fail when comparing the existing cached value with the newly fetched value. 

For any attributes/columns that are updated by the database, modify the entity attribute definition by selecting Refresh after update on the Attribute Settings page of the Entity Object Wizard. 

Use view.executeQuery() frequently, especially after any operations that result in data being changed. 

 

 在eo中添加实现类,然后复写lock方法。

    public void lock() {
        try {
            super.lock();
        } catch (RowInconsistentException e) { 
            refresh(REFRESH_WITH_DB_ONLY_IF_UNCHANGED | REFRESH_CONTAINEES);
            super.lock();
        }
    }

 

分享到:
评论

相关推荐

    兼职小程序源码java-eid-applet:eIDApplet可在Web浏览器中启用BEeID卡

    预约小程序源码java eID 小程序项目的自述文件 一、简介 该项目包含 eID Applet 的源代码树。 源代码托管在: https://github.com/e-Contract/eid-applet : https://github.com/e-Contract/eid-applet ...jbo

    Visual C++学习方法

    介绍VC++系统的学习方法,如何从一个菜鸟成为高手。

    jbo:在命令行上脱机使用jbovlaste

    在命令行上脱机使用jbovlaste。 使用控制台格式将L A T E X格式显示为Unicode纯文本格式使用哈希键值存储进行快速查找预先计算搜索字词并进行评分...(jbo bashrc)现在,您可以git pull changes,而无需再次运行setup.py

    Nhà cái JBO giao dịch nhanh chóng - jbo.vn-crx插件

    来jbo你只需5-10分钟即可完成。 快速交易货币转移的形式,在参加JBO家庭的投注时撤回金钱非常快。与其他经销商相比,您将需要大约半天才能获得账户金钱。但对于jbo来说,你只需要大约5-10分钟。jbo的声望非常高JBO为...

    Jboss-Spring

    jboss-as-sprint-int-5.0.0.GA.jar jboss-spring-int-vfs.jar

    jbo2014.github.io:工作室网站

    jbo2014.github.io工作室网站

    tomcat和jbo共3页.pdf.zip

    tomcat和jbo共3页.pdf.zip

    JBO光学一些新技术

    一些光学方法,新的光学技术,光学相干弹性成像的研究。

    messenger-bot-tutorial, Facebook Messenger bot 15分钟教程.zip

    messenger-bot-tutorial, Facebook Messenger bot 15分钟教程

    ejb_jboss.rar_ejb mysql_ejb_jboss_estoreW_java ejb jbo_jboss

    用JBuilder+Jboos+mysql实现的EJB项目,仅供学习和参考.

    xxl-job2.2.1版本postgresql运行脚本

    xxl-job官网只提供了mysql相关的脚步和mapper文件支持,如果需要在postgresql在执行则需要单独改造,这套资源包括全套脚本+mapper文件,直接替换即可完美在postgresql数据库下运行

    mastersGroupProject:网络数据分析-五年级小组项目

    网络数据分析快速链接到代码 五年应用软件工程小组项目。 该项目涉及对一系列包含电信网络“事件”的数据集进行收集和... 该项目使用的语言,技术和实现体系结构:Java,JavaScript,Eclipse,(基于HTTP的JSON),JBo

    demo:Java EE 7 演示

    演示:使用作为 EAR 部署的多种 Java EE 7 技术的示例作者:Pete Muir 级别:中级技术:EAR 摘要:基于 kitchensink,但部署为 EAR 目标项目:WildFly 来源: : 它是什么?... 该项目生成的应用程序旨在在 JBo

    AD域密码过期邮件提醒

    AD域密码过期邮件提醒,在域计算机设置域帐号密码过期将自动发邮件通知用户,在任务计划添加定时任务,使用bat脚本再调用powshell脚本。bate脚本内容powershell "D:\script\jbo.ps1

    LINUX下JBOSS的安装及配置

    linux系统jboss安装linux系统jboss安装linux系统jboss安装linux系统jboss安装linux系统jboss安装linux系统jboss安装linux系统jboss安装linux系统...linux系统jboss安装linux系统jboss安装linux系统jboss安装linux系统jbo

    QTP_8_用户手册中文版

    第=f=部分:=启动测试流程 第=N=章:=简介.........................................................................................3 使用QuickTest 进行测试...................................................

Global site tag (gtag.js) - Google Analytics