Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

W-16941297: Scatter Gather timeout exception #14192

Open
wants to merge 24 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
5c2b698
handling timeout exception
anandkarandikar Jan 22, 2025
d1b7b3a
Attempt with ExecutorService to process connection closing in the bac…
anandkarandikar Jan 27, 2025
5806098
Remove changes from AbstractEventContext
anandkarandikar Jan 28, 2025
ec561bd
Make ChildEventContext accessible and handle timeout exception in Abs…
anandkarandikar Jan 28, 2025
89d854e
Switch to ioScheduler
anandkarandikar Jan 31, 2025
59dbd95
Change visibility to private for ChildEventContext
anandkarandikar Jan 31, 2025
fce0083
Make AbstractEventContext public
anandkarandikar Jan 31, 2025
7540dc8
Use AbstractEventContext instead of ChildEventContext
anandkarandikar Jan 31, 2025
f3d2532
Remove unused import
anandkarandikar Jan 31, 2025
b1b1390
Handling ClassCastException failure
anandkarandikar Feb 3, 2025
3a90f7d
Merge branch 'master' into fix/W-16941297
anandkarandikar Feb 6, 2025
e66cf94
Add delay to sayMagicWords
anandkarandikar Feb 6, 2025
abadb33
Add tests for Scatter Gather timeout and non timeout scenario
anandkarandikar Feb 7, 2025
835e844
Apply formatter
anandkarandikar Feb 7, 2025
eceee29
Merge branch 'master' into fix/W-16941297
anandkarandikar Feb 7, 2025
8c3e66f
Add assertPayloadIsIteratorProvider check
anandkarandikar Feb 7, 2025
7c2045a
Replace Thread.sleep with CountDownLatch
anandkarandikar Feb 7, 2025
b24c317
Fixing model and schema file for marvel extension
anandkarandikar Feb 7, 2025
82e2d38
Revert the version to @mule.runtime.version@
anandkarandikar Feb 7, 2025
80b3412
Using assertThrows
anandkarandikar Feb 7, 2025
069b02f
Merge branch 'master' into fix/W-16941297
anandkarandikar Feb 8, 2025
fa265ea
Fixing test to make sure it fails when the fix is not present
asanguinetti Feb 11, 2025
282b83b
Avoiding submit, completing the child contexts on timeout emission
asanguinetti Feb 12, 2025
1ade55f
Comment
asanguinetti Feb 12, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ private void handleTimeoutExceptionIfPresent(Scheduler timeoutScheduler,
EventContext context = pair.getFirst().getContext();
if (context instanceof AbstractEventContext) {
((AbstractEventContext) context).forEachChild(ctx -> timeoutScheduler
.submit(() -> ctx.error(error.get().getCause())));
.submit(() -> ctx.error(new MessagingException(pair.getFirst(), error.get().getCause()))));
Copy link
Contributor Author

@anandkarandikar anandkarandikar Feb 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Despite working fine, there were failures in the log

ERROR 2025-01-28 17:26:29,170 [pool-5-thread-2] [processor: ; event: ] org.mule.runtime.core.privileged.processor.MessageProcessors: Uncaught exception in childContextResponseHandler
java.lang.ClassCastException: class java.util.concurrent.TimeoutException cannot be cast to class org.mule.runtime.core.privileged.exception.MessagingException (java.util.concurrent.TimeoutException is in module java.base of loader 'bootstrap'; org.mule.runtime.core.privileged.exception.MessagingException is in module [email protected] of loader jdk.internal.loader.Loader @10cc327a)
	at [email protected]/org.mule.runtime.core.privileged.processor.MessageProcessors.lambda$childContextResponseHandler$14(MessageProcessors.java:582) ~[mule-core-4.9.0-20241025.jar:?]
	at [email protected]/org.mule.runtime.core.internal.event.AbstractEventContext.signalConsumerSilently(AbstractEventContext.java:310) ~[?:?]
	at [email protected]/org.mule.runtime.core.internal.event.AbstractEventContext.receiveResponse(AbstractEventContext.java:210) ~[?:?]
	at [email protected]/org.mule.runtime.core.internal.event.AbstractEventContext.error(AbstractEventContext.java:189) ~[?:?]
	at [email protected]/org.mule.runtime.core.internal.routing.forkjoin.AbstractForkJoinStrategyFactory.lambda$handleTimeoutExceptionIfPresent$6(AbstractForkJoinStrategyFactory.java:173) ~[?:?]

Therefore, creating a MessageException instance

}
}
});
Expand Down