I modified the included Java sample SendFile.java (see below) to use transactional support.
I tried both with AMT.SAMPLE.POLICY snycPoint on and off.
I get the following error:
D:MQSeriesamtsamplesjava>java SF -t SF.java
>>> START AMI Sample SF
create()
open()
SF()
>>> AMI SF experienced an Exception ...
java.lang.Exception: <<< AmError >>>
from method[begin]
of class[AmSession]
with reasonCode[54]
>>> END AMI Sample SF
I modified the SendJava code by renaming the class from SendJava. I then inserted the following line:
mySession.begin();
before the sendFile method and:
mySession.commit();
afterward.
Anyone have success with snycpointing/Java/AMI?
[ This Message was edited by: ebeisher on 2001-11-01 12:25 ]
Joined: 11 Apr 2001 Posts: 1554 Location: Silicon Valley
My first question would be whether or not you are using 2-phase commits under XA? Because if you aren't, you don't need to issue the begin command. As soon as you do an MQGET or MQPUT while specifying syncpointing, a new unit of work should begin. It will continue to grow with subsequent GETs and PUTs, and will be completed once a commit or backout is issued. You only need to issue a begin if you are doing resource coordination with an external system (like a database)...
_________________ Brandon Duncan
IBM Certified MQSeries Specialist
MQSeries.net forum moderator
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum