Skip to content

Add IPendingExecutionRequestState interface to expose completion state of SingleExecuteProtector#1447

Merged
lifengl merged 2 commits into
mainfrom
dev/lifengl/allowDetectingCompletedRequests
Apr 23, 2025
Merged

Add IPendingExecutionRequestState interface to expose completion state of SingleExecuteProtector#1447
lifengl merged 2 commits into
mainfrom
dev/lifengl/allowDetectingCompletedRequests

Conversation

@lifengl

@lifengl lifengl commented Apr 19, 2025

Copy link
Copy Markdown
Member

For customized SynchronizationContext implementation, knowing whether a pending request has been completed could allow it to remove completed requests. Because JTF requests are potentially sent to multiple queues, including the JTF internal queue, many of those requests can be processed especially inside low priority or delayed queues. For low priority queue, completed tasks showing up for high memory usages. This new contract provides a way to make improvements.

This is only for advanced scenarios, common JTF consumers would not access the request or have chance to use it incorrectly.

… a pending request

has been completed could allow it to remove completed requests. Because JTF requests are potentially sent to multiple
queues, including the JTF internal queue, many of those requests can be processed especially inside low priority or delayed queues.
For low priority queue, completed tasks showing up for high memory usages. This new contract provides a way to make improvements.

This is only for advanced scenarios, common JTF consumers would not access the request or have chance to use it incorrectly.
@AArnott AArnott changed the title For customized SynchronizationContext implementation, knowing whether… Add IPendingExecutionRequestState interface to expose completion state of SingleExecuteProtector Apr 21, 2025
@lifengl lifengl merged commit d36a21b into main Apr 23, 2025
@lifengl lifengl deleted the dev/lifengl/allowDetectingCompletedRequests branch April 23, 2025 00:03
This was referenced Jun 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants