Skip to content

Commit ad55516

Browse files
authored
DATACOUCH-958 - Restore auditorAwareRef and dateTimeProviderRef to empty. (#1050)
Restore auditorAwareRef and dateTimeProviderRef to empty. To us them, they will need to be specified in @EnableCouchbaseAuditing( auditorAwareRef="auditorAwareRef", dateTimeProviderRef="dateTimeProviderRef") Co-authored-by: mikereiche <[email protected]>
1 parent 80bae4b commit ad55516

File tree

3 files changed

+3
-5
lines changed

3 files changed

+3
-5
lines changed

src/main/java/org/springframework/data/couchbase/repository/auditing/EnableCouchbaseAuditing.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@
4444
/**
4545
* Configures the {@link AuditorAware} bean to be used to lookup the current principal.
4646
*/
47-
String auditorAwareRef() default "auditorAwareRef";
47+
String auditorAwareRef() default "";
4848

4949
/**
5050
* Configures whether the creation and modification dates are set. Defaults to {@literal true}.
@@ -60,5 +60,5 @@
6060
* Configures a {@link DateTimeProvider} bean name that allows customizing the {@link org.joda.time.DateTime} to be
6161
* used for setting creation and modification dates.
6262
*/
63-
String dateTimeProviderRef() default "dateTimeProviderRef";
63+
String dateTimeProviderRef() default "";
6464
}

src/test/java/org/springframework/data/couchbase/domain/Config.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@
4747
*/
4848
@Configuration
4949
@EnableCouchbaseRepositories
50-
@EnableCouchbaseAuditing // this activates auditing
50+
@EnableCouchbaseAuditing(auditorAwareRef="auditorAwareRef", dateTimeProviderRef="dateTimeProviderRef") // this activates auditing
5151
public class Config extends AbstractCouchbaseConfiguration {
5252
String bucketname = "travel-sample";
5353
String username = "Administrator";

src/test/java/org/springframework/data/couchbase/domain/ConfigScoped.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
package org.springframework.data.couchbase.domain;
1818

1919
import org.springframework.context.annotation.Configuration;
20-
import org.springframework.data.couchbase.repository.auditing.EnableCouchbaseAuditing;
2120
import org.springframework.data.couchbase.repository.config.EnableCouchbaseRepositories;
2221

2322
/**
@@ -28,7 +27,6 @@
2827
*/
2928
@Configuration
3029
@EnableCouchbaseRepositories
31-
@EnableCouchbaseAuditing // this activates auditing
3230
public class ConfigScoped extends Config {
3331

3432
static String scopeName = null;

0 commit comments

Comments
 (0)