Skip to content

add: Update help of --jobs#7297

Merged
daavoo merged 1 commit into
mainfrom
add-jobs-help
Jan 24, 2022
Merged

add: Update help of --jobs#7297
daavoo merged 1 commit into
mainfrom
add-jobs-help

Conversation

@daavoo
Copy link
Copy Markdown
Contributor

@daavoo daavoo commented Jan 20, 2022

@daavoo daavoo requested a review from a team as a code owner January 20, 2022 14:00
@daavoo daavoo requested a review from pared January 20, 2022 14:00
@daavoo daavoo self-assigned this Jan 20, 2022
@daavoo daavoo added the skip-changelog Skips changelog label Jan 20, 2022
Comment thread dvc/commands/add.py
"Only used along with '--to-remote'. "
"Number of jobs to run simultaneously "
"when pushing data to remote."
"The default value is 4 * cpu_count(). "
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

just to double check: is it a correct default value? (I thought it was something like min(4, 4 * cpu_count())? (which we should also update I think)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

It is the current default: https://github.com/iterative/dvc/blob/73fee513b955f1b44542a450318ad42eec850add/dvc/fs/base.py#L36

Do you mean that we should increase the number?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

no, I wanted to double check if it's correct or not - that's it

I always forget which one of those two lines (https://github.com/iterative/dvc/blob/73fee513b955f1b44542a450318ad42eec850add/dvc/fs/base.py#L38) apply to what part.

I would may be check if some file systems override it. Just in case.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

HASH_JOBS is for calculating checksums and can be overridden with core.checksum_jobs.
add jobs refer to to_remote functionality.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I would may be check if some file systems override it. Just in case.

Currently, both _JOBS and HASH_JOBS are never overwritten by any file system.

@daavoo daavoo merged commit 822b501 into main Jan 24, 2022
@daavoo daavoo deleted the add-jobs-help branch January 24, 2022 20:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip-changelog Skips changelog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants