Skip to content

Conversation

analytically
Copy link
Contributor

See #8057

Often the largest volume that may need streaming is the image that the container executes in. By considering this volume too, this may allow for slightly better placement/reduced streaming for some builds (in particular builds with no inputs or caches will now prefer to be on the same worker as their image volume rather than a random one)

Copy link
Member

@taylorsilva taylorsilva left a comment

Choose a reason for hiding this comment

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

I'm not sure this is an assumption we want to bake into the placement strategy. We're assuming that the image artifact is always the volume that takes up the most disk space. We know this is not always the case though.

I'd be open to the latter change this PR makes though, where if there are no other inputs then the image weight is taken into account. That makes sense for all containers in this situation.

@taylorsilva taylorsilva moved this from Todo to In Progress in Pull Requests May 12, 2025
@taylorsilva taylorsilva changed the title atc: Consider image volumes in volume-locality strategy - rebased and added weight atc: Consider image volumes in volume-locality strategy May 12, 2025
@analytically
Copy link
Contributor Author

So you're saying remove the additional (5) weight for the image artifact?

@taylorsilva
Copy link
Member

Yeah dropping the whole weight thing will work. I hadn't looked at the code yet, just read the PR description.

Also realized that the image was never even considered as a volume for this strategy. That alone will be a nice improvement to the strategy.

@analytically
Copy link
Contributor Author

The weight was requested on the original PR by @evanchaoli
screentshot-2025-05-13 at 20 42 17@2x

@taylorsilva
Copy link
Member

taylorsilva commented May 13, 2025

Ah, no one ever reviewed that PR. Evan was also never a maintainer. My feedback is the same.

I'd also like for Andy to get credit for the work done by him. Updating commit message to include him as Co-Author.

Rebase of concourse#8057

Often the largest volume that may need streaming is the image that the
container executes in. By considering this volume too, this may allow
for slightly better placement/reduced streaming for some builds (in
particular builds with no inputs or caches will now prefer to be on the
same worker as their image volume rather than a random one)

Signed-off-by: Mathias Bogaert <mathias.bogaert@gmail.com>
Co-Authored-by: Andy Paine <andy.paine@engineerbetter.com>
@taylorsilva taylorsilva merged commit 0df3a9e into concourse:master May 14, 2025
12 checks passed
@github-project-automation github-project-automation bot moved this from In Progress to Done in Pull Requests May 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants