@@ -644,16 +644,22 @@ finally
644644 <listitem >
645645 <para >
646646 As of NHibernate v5.0, <literal >FlushMode.Commit</literal > requires the configuration setting
647- <literal >transaction.use_connection_on_system_events </literal > to be true for flushing
647+ <literal >transaction.use_connection_on_system_prepare </literal > to be true for flushing
648648 from transaction scope commit. Otherwise, it will be your responsibility to flush the session
649649 before completing the scope.
650650 </para >
651651 <para >
652- Using <literal >transaction.use_connection_on_system_events </literal > can cause undesired
652+ Using <literal >transaction.use_connection_on_system_prepare </literal > can cause undesired
653653 transaction promotions to distributed: it requires using a dedicated connection for flushing,
654654 and it delays session disposal (if done inside the scope) to the scope disposal. If you want
655655 to avoid this, set this setting to <literal >false</literal > and manually flush your sessions.
656656 </para >
657+ <para >
658+ For new applications, it is recommended to set
659+ <literal >transaction.use_connection_on_system_prepare</literal > to <literal >false</literal >,
660+ and to flush explicitly your sessions before scope completion. For old applications, consider
661+ checking how sessions are flushed, and if possible switch it to <literal >false</literal > too.
662+ </para >
657663 </listitem >
658664 <listitem >
659665 <para >
@@ -669,7 +675,7 @@ finally
669675 <literal >Reconnect()</literal > before re-using the session.)
670676 </para >
671677 <para >
672- When using <literal >transaction.use_connection_on_system_events </literal >, if the session is
678+ When using <literal >transaction.use_connection_on_system_prepare </literal >, if the session is
673679 disposed within the scope, the connection releasing will still occurs from transaction
674680 completion event.
675681 </para >
@@ -678,7 +684,7 @@ finally
678684 <para >
679685 As of NHibernate v5.0, using transaction scope and trying to use the session connection within
680686 <literal >AfterTransactionCompletion</literal > is forbidden and will raise an exception.
681- If the setting <literal >transaction.use_connection_on_system_events </literal >
687+ If the setting <literal >transaction.use_connection_on_system_prepare </literal >
682688 is <literal >false</literal >, it will forbid any connection usage from
683689 <literal >BeforeTransactionCompletion</literal > event too, when this event is triggered by
684690 a transaction scope commit or rollback.
0 commit comments