forked from ocurrent/solver-service
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Most of the complexity in the previous version was about managing the child worker processes. With OCaml 5 this all goes away, and we just use multiple domains instead. Notes: - opam is not thread-safe, so we need a lock around all opam file parsing operations. See ocaml/opam#5591 - We now load opam files lazily, which makes testing much faster. This reduces the time for `stress/stress.exe` from 97.4s to 11.5s for me. - Epoch_lock is gone. It was just for managing sub-processes, but a simple Eio.Mutex.t will do now. This should also be much faster when switching between opam-repository commits. - The main executable is now in the `bin` directory. Simplifies the dune file. - test_service.ml is gone. It was only testing parsing of the communications between parent and child processes, which no longer exist. This also removed the need to functorise over opam repository. - Default to `recommended_domain_count - 1` workers. - Removed uses of (non-threadsafe) Str module. TODO: - Bring back parent/child pipe mode. - Integrate worker mode? - Add full stress test (i.e. solving for many packages over many hours).
- Loading branch information
Showing
38 changed files
with
620 additions
and
1,166 deletions.
There are no files selected for viewing
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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
(executable | ||
(name main) | ||
(package solver-service) | ||
(public_name solver-service) | ||
(preprocess | ||
(pps ppx_deriving.std ppx_deriving_yojson)) | ||
(libraries solver-service logs.cli capnp-rpc-unix eio_main dune-build-info logs.fmt logs.threaded fmt.cli fmt.tty)) |
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
File renamed without changes.
File renamed without changes.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
(dirs :standard \ var) | ||
|
||
(vendored_dirs ocluster ocurrent ocaml-dockerfile) | ||
(vendored_dirs ocluster ocurrent ocaml-dockerfile opam-0install-solver) |
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 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 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,14 @@ | ||
(library | ||
(name solver_service) | ||
(public_name solver-service) | ||
(preprocess | ||
(pps ppx_deriving.std ppx_deriving_yojson)) | ||
(libraries | ||
eio_main | ||
eio | ||
lwt_eio | ||
solver-service-api | ||
ppx_deriving_yojson.runtime | ||
prometheus-app | ||
opam-0install | ||
capnp-rpc-unix | ||
capnp-rpc-net | ||
git-unix | ||
ocaml-version | ||
dune-build-info | ||
str | ||
fmt.cli | ||
fmt.tty) | ||
(modules | ||
epoch_lock | ||
git_context | ||
opam_repository | ||
opam_repository_intf | ||
process | ||
remote_commit | ||
internal_worker | ||
service | ||
solver | ||
solver_service)) | ||
|
||
(executable | ||
(name main) | ||
(package solver-service) | ||
(public_name solver-service) | ||
(libraries solver-service logs.cli) | ||
(modules main)) | ||
ocluster-api)) |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.