Is there a nice Kotlin way to do something like Sp...
# random
j
Is there a nice Kotlin way to do something like Spring's
@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:
Copy code
transactional {
  var user = User();
  user.persist();
}
and have the transactional automatically start and end the transaction ?