Revert "Manage asynchronous EventListener with replies"
This reverts commit bee1b77af5.
This commit is contained in:
@@ -155,19 +155,6 @@ public class AnnotationDrivenEventListenerTests {
|
||||
failingContext.refresh();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void asyncWithReplyEventListener() {
|
||||
AnnotationConfigApplicationContext failingContext =
|
||||
new AnnotationConfigApplicationContext();
|
||||
failingContext.register(BasicConfiguration.class,
|
||||
InvalidAsyncEventListener.class);
|
||||
|
||||
this.thrown.expect(BeanInitializationException.class);
|
||||
this.thrown.expectMessage(InvalidAsyncEventListener.class.getName());
|
||||
this.thrown.expectMessage("asyncCannotUseReply");
|
||||
failingContext.refresh();
|
||||
}
|
||||
|
||||
@Test
|
||||
public void simpleReply() {
|
||||
load(TestEventListener.class, ReplyEventListener.class);
|
||||
@@ -669,17 +656,6 @@ public class AnnotationDrivenEventListenerTests {
|
||||
}
|
||||
}
|
||||
|
||||
@Component
|
||||
static class InvalidAsyncEventListener {
|
||||
|
||||
@EventListener
|
||||
@Async
|
||||
public Integer asyncCannotUseReply(String payload) {
|
||||
return 42;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
@Component
|
||||
static class ReplyEventListener extends AbstractTestEventListener {
|
||||
@@ -790,7 +766,6 @@ public class AnnotationDrivenEventListenerTests {
|
||||
this.eventCollector.addEvent(this, event);
|
||||
this.countDownLatch.countDown();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -894,6 +869,7 @@ public class AnnotationDrivenEventListenerTests {
|
||||
}
|
||||
|
||||
|
||||
|
||||
@EventListener
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
public @interface ConditionalEvent {
|
||||
|
||||
Reference in New Issue
Block a user