engine: Rename world API and add a context

We want to be able to pass ctx through for various reasons.
This commit is contained in:
James Shubin
2025-06-02 14:59:41 -04:00
parent 99d8846934
commit 16ade43caf
6 changed files with 26 additions and 26 deletions

View File

@@ -54,11 +54,11 @@ type WorldInit struct {
// GAPI to store state and exchange information throughout the cluster. It is
// the interface each machine uses to communicate with the rest of the world.
type World interface { // TODO: is there a better name for this interface?
// Init sets things up and is called once before any other methods.
Init(*WorldInit) error
// Connect sets things up and is called once before any other methods.
Connect(context.Context, *WorldInit) error
// Close does some cleanup and is the last method that is ever called.
Close() error
// Cleanup does some cleanup and is the last method that is ever called.
Cleanup() error
FsWorld