When you get the fault for the first delete, you probably just need to
call "revertChanges" - either for all changes or just that item.   After
any fault, all messages you commit as part of that batch get reverted -
i.e. put back into the uncommitted list.  When you revert them, we'll
undo those changes - i.e. recreate the deleted item.  This is necessary
to keep the client's view of the managed state in sync with the server's
view.

 

Jeff

 

________________________________

From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf Of billy_d_white
Sent: Monday, February 26, 2007 9:52 AM
To: [email protected]
Subject: [flexcoders] FDS with Java Question: Why is it grouping
requests?

 

Maybe Vroom or one of you other FDS experts can tell my what I'm doing
wrong :

I'm using Cairngorm with a Java/Spring backend. I'm using autocommit
and autosync enabled and when I perform a deleteItem which I want to
fail, it calls my Java assembler which attempts the deletion and
fails. I customize the error message and send it back as a
MessageException. So far so good. 

However, if I then try another deletion, the request is sent to the
assembler with an array of inside the DataMessage and this array
contains the previous delete request as well as the new delete
request. Apparently it is trying to batch the multiple requests since
the previous one failed. (These are stored in that _token_chain_
property of the request) How do I avoid this and make each deletion
request atomic so it will not attempt to execute the previous (failed)
request? Do I need to re-write the service call on the client to use
the manual commit() call or something like that?

Any

 

Reply via email to