[Design of JBoss Transaction Services] - Re: Transaction Status.STATUS_ROLLEDBACK
by huuskart
"mark.little(a)jboss.com" wrote : "huuskart" wrote : When a transaction timeout or some other unexpected situation occurs, the new JBoss transaction manager (in JBoss 4.2.1.GA) marks the transaction into state Status.STATUS_ROLLEDBACK.
| |
|
| Have you read the transaction standards with which we comply? They make it very clear that on a timeout you MUST roll back the transaction. They also make it very clear that data consistency is very important for transaction systems. So any low-level system exception, for instance, should force the transaction to roll back.
|
My point was not at all to complain about the transaction getting rolled back. It is blindingly obvious that it must be rolled back.
My point was that in BMT EJB code, seeing Status.STATUS_ROLLEDBACK is very puzzling, and even more so because you can't commit() nor rollback() the transaction (both throw an exception), nor can you call begin() on it again.
"mark.little(a)jboss.com" wrote : You can always call suspend to remove the thread-to-transaction association.
|
No, I can't. In EJB code, all I have to work with is javax.transaction.UserTransaction, and it does not give me that kind of control (nor would I wish to see such controls in EJB session code).
Sorry, I forgot to mention the version: I'm using JBoss AS 4.2.1.GA.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4163600#4163600
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4163600
17 years, 9 months
[Design of Messaging on JBoss (Messaging/JBoss)] - Re: Handling Large Messages
by ataylor
anonymous wrote : I think we should extend the concept of splitting packets into fragments to other packets too - not just message sends and receives, since other packets have the possibility (however unlikely) of getting large, since there are not fixed length fields like address names in them.
yeah so the 1st way i suggested would do this. basically the encode method of PAcketImpl would be something like:
| public void encode(MessagingBuffer buffer)
| {
| //The standard header fields
| buffer.putInt(0); //The length gets filled in at the end
| buffer.putByte(type);
| buffer.putLong(responseTargetID);
| buffer.putLong(targetID);
| buffer.putLong(executorID);
| buffer.putInt(correlationId);
| buffer.putBoolean(isLastMessage);
| //if we are a small message
| if(!isMultiPartMessage())
| {
| encodeBody(buffer);
| }
| else
| {
| //else write the body to a cache and for each send only write 1k of body to the message
| if(correlationId == 0)
| {
| bodyCache = buffer.createNewBuffer(1024);
| encodeBody(bodyCache);
| }
| buffer.putBytes(bodyCache.array(), correlationId * 1024, 1024);
| }
|
| //The length doesn't include the actual length byte
| int len = buffer.position() - DataConstants.SIZE_INT;
|
| buffer.putInt(0, len);
|
| buffer.flip();
| }
|
Then we just keep on sending the same message but with the next part of the body.
anonymous wrote :
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4163599#4163599
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4163599
17 years, 9 months