to xxedge(好钢用在刀刃上) :不可行,因为业务逻辑不能简单的分割,就是要这样做的话,工作量非常大to ll42002(灰舌):如果A系统同步调用B系统,如果B系统成功提交,但A系统失败,这个时候B系统的数据能回滚吗?
Following are Roc's solutions:solution 1: Do not communication by Socket use web service instead, since we have so much remote invoking solutions, why not choose the better one? for example: EJB, Web Service, JMS, http, socket, in your case, I think web servie is the better one by my intuition. More detail, write webservice on system B in Java(but I am not know C with Web service well, if C can work with Web Service well, this solution is ok);solution 2: if system A know the System B's status(event), this issue is easy to handle, after system A sent invoke message(event) to System b, system b sent status(eventResponse) back to system A, accord B's feedback to handle system A's transaction;solution 3: I have a remote invoke solution which support isomerous architecture and based on http protocal, I think it can help you to do this work. The bad news is I can not share with you all currently, the good news is I want to open its source recently(maybe after labor festival :) ).Regards, Roc
1:不知道有没有这种EAI产品,交易中间件或开源实现?2:http://www.jdon.com/jive/thread.jsp?forum=46&thread=23422中提到J2EE --> JMS --> cobol,不知道具体怎么做?非常感谢各位高手!
上面的论坛中说可以通过jms实现,我不是很明白,请高手解释一下!
跨平台的语言是Java ,跨语言的技术是 Web Service ,数据库也用的是同一个数据库,感觉有可能实现
例如所有的数据库操作由C来做,java这边需要读取或更新数据数据库都通过
socket等方式经由C来实现呢
这样能不能控制所有的事务
Roc
http://community.csdn.net/Expert/topic/4723/4723081.xml?temp=.4756128
但是具体操作还不了解,请大家继续关注!
判断一下呀。A调用B的时候判断B调用是否成功,如果失败就抛出一个异常,让A回滚。
因为B也是作为事务执行,这样B自然是先回滚了。
楼上的也许是个不错的主意