Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

docs: add documentation for prebuild scheduling feature#18462

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged

Conversation

evgeniy-scherbina
Copy link
Contributor

@evgeniy-scherbinaevgeniy-scherbina commentedJun 19, 2025
edited
Loading

Follow-up to#18126

Changes:

@evgeniy-scherbinaevgeniy-scherbinaforce-pushed theyevhenii/prebuilds-autoscaling-mechanism branch 4 times, most recently from21c9c1a tob92ae48CompareJune 19, 2025 20:30
@evgeniy-scherbinaevgeniy-scherbinaforce-pushed theyevhenii/prebuilds-autoscaling-mechanism branch fromb92ae48 tod26f663CompareJune 19, 2025 20:39
@evgeniy-scherbinaevgeniy-scherbina marked this pull request as ready for reviewJune 19, 2025 20:39
@evgeniy-scherbinaevgeniy-scherbina changed the titlerefactor: change calculate-actions function signaturedocs: add documentation for prebuild scheduling featureJun 19, 2025
Copy link
Contributor

@dannykoppingdannykopping left a comment

Choose a reason for hiding this comment

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

Fantastic documentation!

@evgeniy-scherbinaevgeniy-scherbina merged commit8e3022e intomainJun 20, 2025
36 checks passed
@evgeniy-scherbinaevgeniy-scherbina deleted the yevhenii/prebuilds-autoscaling-mechanism branchJune 20, 2025 14:08
@github-actionsgithub-actionsbot locked and limited conversation to collaboratorsJun 20, 2025
Copy link
Contributor

@ssncferreirassncferreira left a comment

Choose a reason for hiding this comment

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

LGTM 🚀 just some small nits

instances = 0 # default to 0 instances
scheduling {
timezone = "UTC" # only a single timezone may be used for simplicity
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: add the list of supported timezones

**How scheduling works:**

1. The reconciliation loop evaluates all active schedules every reconciliation interval (`CODER_WORKSPACE_PREBUILDS_RECONCILIATION_INTERVAL`).
2. The schedule that matches the current time becomes active. Overlapping schedules are disallowed by validation rules.
Copy link
Contributor

Choose a reason for hiding this comment

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

small nit:

Suggested change
2. The schedulethat matchesthe current timebecomesactive. Overlapping schedules aredisallowed by validation rules.
2. The schedulematchingthe current timeis consideredactive. Overlapping schedules areprevented by validation rules.


1. The reconciliation loop evaluates all active schedules every reconciliation interval (`CODER_WORKSPACE_PREBUILDS_RECONCILIATION_INTERVAL`).
2. The schedule that matches the current time becomes active. Overlapping schedules are disallowed by validation rules.
3. If no schedules match the current time, the base`instances` count is used.
Copy link
Contributor

Choose a reason for hiding this comment

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

small nit:

Suggested change
3. If noschedules match the current time, the base`instances` count is used.
3. If noschedule matches the current time, thesystem defaults to thebase`instances` count.

Cron expressions follow the format:`* HOUR DOM MONTH DAY-OF-WEEK`

-`*` (minute): Must always be`*` to ensure the schedule covers entire hours rather than specific minute intervals
-`HOUR`: 0-23, range (e.g., 8-18 for 8AM-6:59PM), or`*`
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe use the same time interval for consistency:

Suggested change
-`HOUR`:0-23, range (e.g., 8-18 for 8AM-6:59PM), or`*`
-`HOUR`:8-18, range (e.g., 8-18 for 8AM-6:59PM), or`*`

instances = 10
}
schedule {
cron = "* 19-23,0-7 * * 1,5" # Evenings and nights (7PM-11:59PM, 12AM-7:59AM, Mon-Fri)
Copy link
Contributor

Choose a reason for hiding this comment

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

Wow, it is possible to compose multiple hour intervals? Nice 🤩

Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.
Reviewers

@matifalimatifalimatifali left review comments

@dannykoppingdannykoppingdannykopping approved these changes

@ssncferreirassncferreirassncferreira approved these changes

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

4 participants
@evgeniy-scherbina@dannykopping@ssncferreira@matifali

[8]ページ先頭

©2009-2025 Movatter.jp