Skip to content

Make BaseBatchedJob TTR aware#16947

Merged
brandonkelly merged 11 commits into4.15from
feature/batch-job-ttr
Mar 28, 2025
Merged

Make BaseBatchedJob TTR aware#16947
brandonkelly merged 11 commits into4.15from
feature/batch-job-ttr

Conversation

@timkelty
Copy link
Copy Markdown
Contributor

@timkelty timkelty commented Mar 24, 2025

Description

In addition to memory usage, also tracks running time and compares against TTR

Comment thread src/queue/BaseBatchedJob.php Outdated
Comment thread src/queue/BaseBatchedJob.php Outdated
@brandonkelly brandonkelly changed the base branch from 5.x to 4.15 March 26, 2025 15:11
@brandonkelly brandonkelly force-pushed the feature/batch-job-ttr branch from c8df5da to 835f94f Compare March 26, 2025 15:11
@brandonkelly
Copy link
Copy Markdown
Member

Allows batchSize to be null, allowing batching to be solely determined by TTR.

@timkelty did you test this? craft\base\Batchable::getSlice() (called from execute()) requires $limit to be an int.

@timkelty
Copy link
Copy Markdown
Contributor Author

timkelty commented Mar 26, 2025

@timkelty did you test this? craft\base\Batchable::getSlice() (called from execute()) requires $limit to be an int.

Apparently not well enough…I guess PHPstan was happy because we don't have strict_types=1
Anyway, fixed now.

Comment thread src/queue/BaseBatchedJob.php Outdated
@brandonkelly brandonkelly merged commit b169972 into 4.15 Mar 28, 2025
@brandonkelly brandonkelly deleted the feature/batch-job-ttr branch March 28, 2025 00:56
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.

3 participants