DATAMONGO-2586 - Polishing.
Add tests to ensure no reactive auditing callback is registered when using imperative configuration and vice versa. Update wording and minor code style tweaks. Original Pull Request: #877
This commit is contained in:
@@ -30,9 +30,10 @@ To activate auditing functionality via XML, add the Spring Data Mongo `auditing`
|
||||
----
|
||||
====
|
||||
|
||||
If you wish to use auditing with the reactive programming model, then enable auditing through `@EnableReactiveMongoAuditing`
|
||||
To enable auditing, leveraging a reactive programming model, use the `@EnableReactiveMongoAuditing` annotation. +
|
||||
If you expose a bean of type `ReactiveAuditorAware` to the `ApplicationContext`, the auditing infrastructure picks it up automatically and uses it to determine the current user to be set on domain types. If you have multiple implementations registered in the `ApplicationContext`, you can select the one to be used by explicitly setting the `auditorAwareRef` attribute of `@EnableReactiveMongoAuditing`.
|
||||
|
||||
.Activating auditing using JavaConfig
|
||||
.Activating reactive auditing using JavaConfig
|
||||
====
|
||||
[source,java]
|
||||
----
|
||||
@@ -47,5 +48,5 @@ class Config {
|
||||
}
|
||||
----
|
||||
====
|
||||
If you expose a bean of type `ReactiveAuditorAware` to the `ApplicationContext`, the auditing infrastructure picks it up automatically and uses it to determine the current user to be set on domain types. If you have multiple implementations registered in the `ApplicationContext`, you can select the one to be used by explicitly setting the `auditorAwareRef` attribute of `@EnableReactiveMongoAuditing`.
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user