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

daemon: Instantiate one lookup formula for each segment in a path #2098

Open
rekmarks opened this issue Feb 22, 2024 · 1 comment
Open

daemon: Instantiate one lookup formula for each segment in a path #2098

rekmarks opened this issue Feb 22, 2024 · 1 comment
Labels
daemon Issues pertaining the the pet dæmon 🐈‍⬛ enhancement New feature or request

Comments

@rekmarks
Copy link
Contributor

Lookup formulas currently correspond to a pet name path of length at least 2, and the value resolved thereby. We should instead create a lookup formula for each path segment, and store a reference to the parent segment formula in each child. Ideally, we should be able to synchronously retrieve existing formulas for a given pet name path, provided that the path is local to the current daemon.

@rekmarks rekmarks added the enhancement New feature or request label Feb 22, 2024
@rekmarks
Copy link
Contributor Author

@kriskowal, I believe we originally planned to derive child segment formula numbers from their parents, but #2089 removed derivation in favor of randomly generating all formula numbers. Can we reintroduce derivation for this purpose? It seems problematic if we're also trying to ensure that formula numbers are never reused.

rekmarks added a commit that referenced this issue Feb 22, 2024
Fixes: #2021
Progresses: #2086
Ref: #2098

Synchronizes the host's `evaluate()` method by delegating all incarnations to the daemon via `incarnateEval()`. The latter is responsible for incarnating its dependents as necessary, and for the generation of their formula numbers. To facilitate this, the synchronous methods `incarnateLookupSync()` and `incarnateWorkerSync()` have been added. These methods synchronously mutate the formula graph, and return promises that resolve when the formulas have been written to disk. The result is that the formula graph is mutated within a single turn of the event loop.
@kriskowal kriskowal added the daemon Issues pertaining the the pet dæmon 🐈‍⬛ label Apr 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
daemon Issues pertaining the the pet dæmon 🐈‍⬛ enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants