Skip to content

Conversation

@bjlaub
Copy link
Contributor

@bjlaub bjlaub commented Jan 22, 2026

Allow overriding deadline state temporarily within a try-with-resources block. This implementation uses a ThreadLocal, and can only change the deadline state for the calling thread, so care should be taken to limit uses to scenarios where a single thread must run a small operation with an alternate deadline. Other threads will be unaffected.

Before this PR

After this PR

==COMMIT_MSG==
==COMMIT_MSG==

Possible downsides?

Allow overriding deadline state temporarily within a try-with-resources
block. This implementation uses a ThreadLocal, and can only change the
deadline state for the calling thread, so care should be taken to limit
uses to scenarios where a single thread must run a small operation with
an alternate deadline. Other threads will be unaffected.
@changelog-app
Copy link

changelog-app bot commented Jan 22, 2026

Generate changelog in changelog/@unreleased

Type (Select exactly one)

  • Feature (Adding new functionality)
  • Improvement (Improving existing functionality)
  • Fix (Fixing an issue with existing functionality)
  • Break (Creating a new major version by breaking public APIs)
  • Deprecation (Removing functionality in a non-breaking way)
  • Migration (Automatically moving data/functionality to a new system)

Description

implement scoped deadlines

Check the box to generate changelog(s)

  • Generate changelog entry

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