Skip to content

Conversation

@gaius-qi
Copy link
Member

Description

This pull request makes adjustments to configuration defaults and validation rules in the job management system. The key changes include reducing the default concurrency for image distribution jobs and adding stricter validation for preheating arguments.

Configuration Updates:

  • manager/service/job.go: Reduced the default value for DefaultGetImageDistributionJobConcurrentCount from 30 to 12 to optimize resource usage during image distribution jobs.

Validation Enhancements:

  • manager/types/job.go: Added validation constraints to the IPs field in the PreheatArgs struct, ensuring the list contains between 1 and 100 entries (gte=1,lte=100). This prevents invalid or overly large input.

Related Issue

Motivation and Context

Screenshots (if appropriate)

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation Update (if none of the other choices apply)

Checklist

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.

… IPs

Signed-off-by: Gaius <gaius.qi@gmail.com>
@gaius-qi gaius-qi added this to the v2.4.0 milestone Jul 21, 2025
@gaius-qi gaius-qi self-assigned this Jul 21, 2025
@gaius-qi gaius-qi requested a review from a team as a code owner July 21, 2025 04:02
@gaius-qi gaius-qi added the enhancement New feature or request label Jul 21, 2025
Copy link
Member

@chlins chlins left a comment

Choose a reason for hiding this comment

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

lgtm

@chlins chlins enabled auto-merge (squash) July 21, 2025 04:06
@codecov
Copy link

codecov bot commented Jul 21, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 32.58%. Comparing base (94a02a2) to head (71379c3).
Report is 1 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #4219   +/-   ##
=======================================
  Coverage   32.58%   32.58%           
=======================================
  Files         350      350           
  Lines       41288    41288           
=======================================
  Hits        13452    13452           
  Misses      26945    26945           
  Partials      891      891           
Flag Coverage Δ
unittests 32.58% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
manager/service/job.go 0.00% <ø> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link

@Liam-Zhao Liam-Zhao left a comment

Choose a reason for hiding this comment

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

LGTM

@chlins chlins merged commit f9d576d into main Jul 21, 2025
18 checks passed
@chlins chlins deleted the feature/limit branch July 21, 2025 04:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants