Skip to content
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

Fixing the issue of the CI not responding #888

Merged
merged 1 commit into from
Oct 24, 2023

Conversation

moyodiallo
Copy link
Contributor

With @mtelvers we identify where the issue about the CI not responding when there's a lot of activity, meaning when there's a new push in opam-repo the analysis of all user repositroy is restarted.

An analysis makes a tmp copy of an user repository in order to extract all the information needed for the solver-service. There's some IO access involved and take time when there's a lot of analysis running at same time in the CI.

This is an attempt to fix that, by cache the extraction without keep doing it for each new opam repository commit.

Copy link
Contributor

@benmandrew benmandrew left a comment

Choose a reason for hiding this comment

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

I don't have the background to tell if this solves the problem, but it at least looks sensible and works on my machine 👍

@mtelvers
Copy link
Member

mtelvers commented Oct 6, 2023

Some more context here. Looking at a run such as run 51 nearly an hour is lost between the start and the cp line. At this time, OCaml-CI is cloning the repo from GitHub. At other times, such as run 52 or run 50 the git clone is very fast. It's not clear why there is such a difference, but it could be down to rate limiting from GitHub. This PR should cache the result of the clone to avoid repeating it with the same commit. I suggest we push it to live-engine and see how it performs in the real world.

@moyodiallo
Copy link
Contributor Author

I suggest we push it to live-engine and see how it performs in the real world.

I pushed it on live-engine. It is deploying right now.

@mtelvers
Copy link
Member

mtelvers commented Oct 6, 2023

This appears to be working. The Fetch and Extract stages are not repeated but Analyse is run as expected.

image

With Mark Elvers we identify where the issue about the CI not
responding when there's a lot of activity, meaning when there's a new
push in opam-repo the analysis of all user repositroy is restarted.

An analysis makes a tmp copy of an user repository in order to extract
all the information needed for the solver-service. There's some IO access
involved and take time when there's a lot of analysis running at same
time in the CI.

This is an attempt to fix that, by cache the extraction without keep
doing it for each new opam repository commit.
@benmandrew
Copy link
Contributor

@moyodiallo can this be merged?

@moyodiallo
Copy link
Contributor Author

@moyodiallo can this be merged?

Yes.

@moyodiallo moyodiallo merged commit 5fd9105 into ocurrent:master Oct 24, 2023
2 checks passed
@moyodiallo moyodiallo deleted the extract-content branch October 24, 2023 14:11
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.

3 participants