I have to use 3 different transaction managers in my webapp. So I wrote my own Annotation according to the Spring reference (Section 10.5.6.3 Custom shortcut annotations).
One annotation (for using one specific transactionmanager) looks like this:
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import j...
Mapped objects are not being persisted in DB (Postgresql 8.4) when calling persist in a running transaction. I am using Spring Transaction Management with the
org.springframework.jdbc.datasource.DataSourceTransactionManager
so everything should be fine. I set the autocommit-mode on the DataSource to "false". When setting the mode ...
I'm using Spring 2.5 transaction management and I have the following set-up:
Bean1
@Transactional(noRollbackFor = { Exception.class })
public void execute() {
try {
bean2.execute();
} catch (Exception e) {
// persist failure in database (so the transaction shouldn't fail)
// the exception is not re-thrown
}
}
Bean2
...
Firstly it is possible that I am asking something that has been asked and answered before but I could not get a search result back . Okay generally (or always so far:) ) We define transactional annotations on service layer typical spring hibernate crud is usually
Controller->Manager->Dao->Orm .
I now have a situation where I need to ch...
I would like to be able to verify if each unit of work is done in its own transaction, or as part of a single global transaction.
I have a method (defined using spring and hibernate), which is of the form:
private void updateUser() {
updateSomething();
updateSomethingElse();
}
This is called from two places, the website when ...