MessagingAnnotationPostProcessor now requires the class-level @MessageEndpoint annotation.

This commit is contained in:
Mark Fisher
2008-08-28 18:25:15 +00:00
parent 023bf6cbd8
commit 62c7439960
3 changed files with 10 additions and 0 deletions

View File

@@ -82,6 +82,9 @@ public class MessagingAnnotationPostProcessor implements BeanPostProcessor, Init
Object originalBean = bean;
Class<?> beanClass = this.getBeanClass(bean);
MessageEndpoint endpointAnnotation = AnnotationUtils.findAnnotation(beanClass, MessageEndpoint.class);
if (endpointAnnotation == null) {
return bean;
}
for (Map.Entry<Class<?>, AnnotationMethodPostProcessor> entry : this.postProcessors.entrySet()) {
AnnotationMethodPostProcessor postProcessor = entry.getValue();
bean = postProcessor.postProcess(bean, beanName, beanClass);