Skip to content

Conversation

@ashfame
Copy link
Owner

@ashfame ashfame commented Oct 13, 2025

fixes #29

@ashfame ashfame self-assigned this Oct 13, 2025
@ashfame ashfame requested a review from Copilot October 28, 2025 13:40
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR improves the calculation of maximum execution time for long polling by dynamically determining available execution time based on PHP's max_execution_time setting and elapsed request time, rather than using a hardcoded 30-second value.

Key Changes:

  • Introduced get_available_execution_time() method to calculate remaining execution time
  • Updated polling logic to use available execution time instead of hardcoded value
  • Added safety buffer to prevent timeouts during shutdown tasks

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@ashfame ashfame marked this pull request as ready for review October 29, 2025 10:51
@ashfame ashfame merged commit 5559fea into main Oct 29, 2025
1 check passed
@ashfame ashfame deleted the better_php_max_execution_handling branch October 29, 2025 10:52
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.

Better PHP max execution time limit to avoid premature termination of long polling request

2 participants