[hibernate-dev] Interceptors and dependency injection
guillaume.smet at gmail.com
Thu Dec 14 03:43:02 EST 2017
Hi all (and Steve especially as it seems you are working on the
subject right now),
You talking about CDI made me think of something we did at
$previousJob a long time ago.
I didn't quite follow what you did in 6 about CDI/Spring injection but
basically the requirement was to be able to create Spring managed
interceptors and to inject them in the PersistenceProvider.
At the time, we ended up with the following:
But I think it would probably be nice if we could inject them directly.
Another thing we did which is not really related is creating a
ChainedInterceptor to be able to define several interceptors (the idea
was that we did want the ability to enable some interceptors at will
depending on what a given application required).
Just injecting the interceptors in a random order would probably not
do it as I think you will probably want to define them in an ordered
Not sure it's useful but I thought I might as well talk about it now
that you are working on this feature.
Have a nice day.
More information about the hibernate-dev