FOUR-12686: Restart processmaker:consume command(s) when config changes#5756
Merged
ryancooley merged 4 commits intodevelopfrom Dec 4, 2023
Merged
Conversation
|
SonarQube Quality Gate |
caleeli
approved these changes
Dec 4, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.








Issue
All ProcessMaker settings are persisted in the database, but are also set in the laravel
config(). When the config is cached, it is stored inbootstrap/cache/config.php, which each instance of the app uses when booting up.Currently, we restart the job queue by listening for config changes since it is a long-running command (
php artisan horizon) and only reads frombootstrap/cache/config.phponce when it starts.When testing an Actions By Email feature, the settings changes which were made were not picked up by the (more recent)
processmaker:consumeartisan command, which is also long-running. This caused an exception to be thrown in theprocessmaker:consumecommand's process when the ABE email was attempted to be sent.Solution
Call the
kafka:restart-consumerscommand to restart all running commands to pick up the new configuration change.Reproduction Steps
php artisan config:cache)processmaker:consumecommand and notice the errorsHow to Test
Run through the reproduction steps 3-6 and ensure the
processmaker:consumecommand is restartedRelated Tickets & Packages
Code Review Checklist