Andrea Giovacchini
Andrea Giovacchini

Reputation: 5187

Is there a way I can use an Interceptor in NHibernate 4.0 with stateless session?

I have a big pre-exisiting project which was using NHibernate 2 with stateless session which used interceptors for altering values before CRUD operations (eg: timestamps of insert/update/ecc.); now after upgrading to NHibernate 4 I see that there is a design choice to not call interceptors for stateless sessions and I can't find a workaround, has anyone faced a problem like this and may there be a solution?

Upvotes: 1

Views: 553

Answers (1)

Rabban
Rabban

Reputation: 2581

You can use Event Listeners instead. Ayende wrote a post in his blog about this.

Upvotes: 1

Related Questions