Consistent use of @Nullable across the codebase (even for internals)
Beyond just formally declaring the current behavior, this revision actually enforces non-null behavior in selected signatures now, not tolerating null values anymore when not explicitly documented. It also changes some utility methods with historic null-in/null-out tolerance towards enforced non-null return values, making them a proper citizen in non-null assignments. Some issues are left as to-do: in particular a thorough revision of spring-test, and a few tests with unclear failures (ignored as "TODO: NULLABLE") to be sorted out in a follow-up commit. Issue: SPR-15540
This commit is contained in:
@@ -22,7 +22,7 @@
|
||||
|
||||
<cache:annotation-driven mode="aspectj" key-generator="keyGenerator"/>
|
||||
|
||||
<bean id="keyGenerator" class="org.springframework.cache.config.SomeKeyGenerator" />
|
||||
<bean id="keyGenerator" class="org.springframework.cache.config.SomeKeyGenerator"/>
|
||||
|
||||
<bean id="cacheManager" class="org.springframework.cache.support.SimpleCacheManager">
|
||||
<property name="caches">
|
||||
@@ -40,7 +40,7 @@
|
||||
</property>
|
||||
</bean>
|
||||
|
||||
<bean id="customKeyGenerator" class="org.springframework.cache.config.SomeCustomKeyGenerator" />
|
||||
<bean id="customKeyGenerator" class="org.springframework.cache.config.SomeCustomKeyGenerator"/>
|
||||
|
||||
<bean id="customCacheManager" class="org.springframework.cache.support.SimpleCacheManager">
|
||||
<property name="caches">
|
||||
@@ -55,6 +55,7 @@
|
||||
<bean id="debugInterceptor" class="org.springframework.aop.interceptor.DebugInterceptor"/>
|
||||
|
||||
<bean id="service" class="org.springframework.cache.config.DefaultCacheableService"/>
|
||||
|
||||
<bean id="classService" class="org.springframework.cache.config.AnnotatedClassCacheableService"/>
|
||||
|
||||
</beans>
|
||||
|
||||
Reference in New Issue
Block a user