-
Notifications
You must be signed in to change notification settings - Fork 63
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Maintenance: use the correct object directory #470
Merged
derrickstolee
merged 6 commits into
microsoft:main
from
derrickstolee:maintenance-object-dir
Dec 17, 2020
Merged
Maintenance: use the correct object directory #470
derrickstolee
merged 6 commits into
microsoft:main
from
derrickstolee:maintenance-object-dir
Dec 17, 2020
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This allows running the same tests in both "scalar run" and "git maintenance run" modes. The actual logic based on this bit of information is not actually included yet. Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
To check if Git's official background maintenance is ready for a full Scalar repo, add tests that check for how 'git maintenance run --task=loose-objects' compare to 'scalar run loose-objects'. The biggest difference is that 'scalar run <task>' sets GIT_OBJECT_DIRECTORY to the shared object cache before running 'git maintenance run --task=<task>', so we need to make Git do that, too. THIS COMMIT CAUSES FUNCTIONAL TEST FAILURES. These will be fixed in the next commit. Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
This change works without a hitch. Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
Switch based on the test harness to use 'git maintenance run' as well as 'scalar run' for the commit-graph task. The one clear deviation is that we cannot have Git clean up the .lock file, since that violates Git's expectations. That's a meaningful behavior difference (that hopefully won't matter?) so let's attempt to fix that problem. Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
Use the 'git maintenance run --task=prefetch' the same was as 'scalar run fetch' to maximize our test coverage. Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
See microsoft/git#301. Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
derrickstolee
force-pushed
the
maintenance-object-dir
branch
from
December 15, 2020 14:36
3fe5aed
to
70b68e0
Compare
derrickstolee
changed the title
[PR Build] Maintenance: use the correct object directory
Maintenance: use the correct object directory
Dec 15, 2020
mjcheetham
approved these changes
Dec 17, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good to me
dscho
reviewed
Dec 17, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not an expert, just two small comments/questions.
Scalar.FunctionalTests/Tests/EnlistmentPerFixture/CommitGraphStepTests.cs
Show resolved
Hide resolved
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In #458, we dropped the
Scalar.Service
application from the macOS platform and depended entirely ongit maintenance start
to initialize background maintenance. This had two issues:cron
-based background maintenance does not sufficiently create a user environment for GCM Core to store credentials. This causes it to start loading pop-ups on the hour every hour for theprefetch
task. This item is handled upstream asds/maintenance-part-4
, which creates platform-specific maintenance abilities, including macOS integration withlaunchd
/launchctl
.git maintenance run --task=<task>
insidescalar run <job>
, I forgot thatscalar run
setsGIT_OBJECT_DIRECTORY
so something inside ofgit maintenance run
needs to do the same. This is being answered by Update 'git maintenance' to match upstream git#301.As for Scalar, the only thing we need to do is consume this new version of Git and test that
git maintenance run
does the same thing asscalar run
. Hold it to the same standards.Review commit-by-commit to avoid being overwhelmed with scaffolding for the multi-mode test classes.