Skip to content

Conversation

@vlerdman
Copy link

What is the problem I am trying to address?

Currently stash has hardcoded 10 minutes timeout which may leads to timeout errors.

How is the fix applied?

Add timeout field to stasher for using in Stash call. It's configurable via ATHENS_TIMEOUT var.

What GitHub issue(s) does this PR fix or close?

Fixes #1964
Fixes #1960

@vlerdman vlerdman requested a review from a team as a code owner January 15, 2025 09:42
return err
}
st := stash.New(mf, s, indexer, stash.WithPool(c.GoGetWorkers), withSingleFlight)
st := stash.New(mf, s, indexer, c.TimeoutDuration(), stash.WithPool(c.GoGetWorkers), withSingleFlight)
Copy link
Member

Choose a reason for hiding this comment

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

If you are reusing the ATHENS_TIMEOUT variable, I'd suggest documenting that it now also serves this purpose.

Also, I don't know if there is a direct correlation between the timeout users might want to use for the VCS lister and for the stash. I'll let the others decide on whether it should be separate timeouts or not.

Copy link
Author

Choose a reason for hiding this comment

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

Thanks for comment! Also want to mention, that stasher uses storage backend for uploading files, and for some providers (for example s3) it uses ATHENS_TIMEOUT as timeout for upload operations. It was a reason for reusing ATHENS_TIMEOUT instead of adding separete var, as for me it would be more clear behaviour.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Make Stash timeout configurable

2 participants