janvladimirmostert
11/04/2016, 11:46 AM@Transactional
even if it's without an annotation?
I believe Spring is using AspectJ or Aspect Orientatated Programming to inject code before and after the method if annotated with `@Transactional`;
typically before your code starts, @Transactional
will inject a begin transaction and before the method finishes, do a end transaction.
Would it be possible to do something like this:
transactional {
var user = User();
user.persist();
}
and have the transactional automatically start and end the transaction ?