Harmony 1985 - Add cron service to run scheduled jobs#702
Merged
indiejames merged 10 commits intomainfrom Feb 21, 2025
Merged
Conversation
chris-durbin
approved these changes
Feb 20, 2025
Contributor
chris-durbin
left a comment
There was a problem hiding this comment.
I tested it out successfully running in developer mode (not harmony in a box).
| envsubst < $file | kubectl apply -f - -n harmony | ||
|
|
||
| # create the work failer | ||
| file="services/work-failer/config/service-template.yaml" |
Contributor
There was a problem hiding this comment.
Why is the work-failer removed?
Contributor
Author
There was a problem hiding this comment.
it was a mistake - fixed
| import { CronJob } from './cronjob'; | ||
|
|
||
| /** | ||
| * Find work items that are older than notUpdatedForMinutes and delete them. |
Contributor
There was a problem hiding this comment.
Nit: indentation looks off for the JSDocs for this and the next function.
ygliuvt
reviewed
Feb 20, 2025
bin/deploy-services
Outdated
| exit 1 | ||
| fi | ||
| envsubst < $file | kubectl apply -f - -n harmony | ||
| fi |
Member
There was a problem hiding this comment.
This line should be removed otherwise you get syntax error because the fi won't match on line 68.
ygliuvt
reviewed
Feb 20, 2025
bin/deploy-services
Outdated
| fi | ||
|
|
||
| # create the work failer | ||
| # create the work failer |
ygliuvt
approved these changes
Feb 21, 2025
Member
ygliuvt
left a comment
There was a problem hiding this comment.
Tested successfully with harmony in a box.
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.
Jira Issue ID
HARMONY-1985
Description
Adds a cron service that can run scheduled jobs and move work-reaper functionality to it.
Local Test Steps
For harmony in a box:
npm run buildin theservices/cron-servicedirectory.envfile to make thework-reaperrun every minute and to have it reap any work-items and workflow-steps that are more than 1 minute old, so you will be able to see things happening faster:k9sorkubectlto verify that thecron-servicemicroservice is running, then tail the log on the podFor sandbox:
./bin/deployin the harmony-ci-cd directoryPR Acceptance Checklist