Polishing
This commit is contained in:
parent
a68f5b1674
commit
9f7cbe1234
|
|
@ -289,19 +289,15 @@ final class AnnotationTypeMapping {
|
||||||
int mapped = rootAttributes.indexOf(name);
|
int mapped = rootAttributes.indexOf(name);
|
||||||
if (!MergedAnnotation.VALUE.equals(name) && mapped != -1 && !isExplicitAttributeOverride(name)) {
|
if (!MergedAnnotation.VALUE.equals(name) && mapped != -1 && !isExplicitAttributeOverride(name)) {
|
||||||
String rootAnnotationTypeName = this.root.annotationType.getName();
|
String rootAnnotationTypeName = this.root.annotationType.getName();
|
||||||
// We want to avoid duplicate log warnings as much as possible, without
|
|
||||||
// fully synchronizing on the cache.
|
|
||||||
String cacheKey = rootAnnotationTypeName + "." + name;
|
String cacheKey = rootAnnotationTypeName + "." + name;
|
||||||
if (!conventionBasedOverrideCheckCache.contains(cacheKey)) {
|
// We want to avoid duplicate log warnings as much as possible, without full synchronization.
|
||||||
conventionBasedOverrideCheckCache.add(cacheKey);
|
if (conventionBasedOverrideCheckCache.add(cacheKey) && logger.isWarnEnabled()) {
|
||||||
if (logger.isWarnEnabled()) {
|
logger.warn("""
|
||||||
logger.warn("""
|
Support for convention-based annotation attribute overrides is \
|
||||||
Support for convention-based annotation attribute overrides is \
|
deprecated and will be removed in Spring Framework 6.1. Please \
|
||||||
deprecated and will be removed in Spring Framework 6.1. Please \
|
annotate the '%s' attribute in @%s with an appropriate @AliasFor \
|
||||||
annotate the '%s' attribute in @%s with an appropriate @AliasFor \
|
declaration."""
|
||||||
declaration."""
|
.formatted(name, rootAnnotationTypeName));
|
||||||
.formatted(name, rootAnnotationTypeName));
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
mappings[i] = mapped;
|
mappings[i] = mapped;
|
||||||
MirrorSet mirrors = getMirrorSets().getAssigned(i);
|
MirrorSet mirrors = getMirrorSets().getAssigned(i);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue