Skip to content

Commit 28c2533

Browse files
LinkedListmp911de
authored andcommitted
DATAMONGO-1205 - Log only CyclicPropertyReferenceException message.
We log CyclicPropertyReferenceException with its message only and removed the stack trace from the log. The stacktrace points to a verifier location and is not particularly useful in finding the offending code. This change creates consistency over how CyclicPropertyReferenceException is logged. Original pull request: #397.
1 parent cf4c76a commit 28c2533

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

spring-data-mongodb/src/main/java/org/springframework/data/mongodb/core/index/MongoPersistentEntityIndexResolver.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@ public void doWithPersistentProperty(MongoPersistentProperty persistentProperty)
264264
appendTextIndexInformation(propertyDotPath, indexDefinitionBuilder,
265265
mappingContext.getPersistentEntity(persistentProperty.getActualType()), optionsForNestedType, guard);
266266
} catch (CyclicPropertyReferenceException e) {
267-
LOGGER.info(e.getMessage(), e);
267+
LOGGER.info(e.getMessage());
268268
} catch (InvalidDataAccessApiUsageException e) {
269269
LOGGER.info(String.format("Potentially invalid index structure discovered. Breaking operation for %s.",
270270
entity.getName()), e);

0 commit comments

Comments
 (0)