-
Notifications
You must be signed in to change notification settings - Fork 16
[Service] Turns Service into an Actor and splits service into its own files #69
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
Conversation
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.
One general question, but overall looks good
src/forge/controller/interface.py
Outdated
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.
Why is this needed?
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.
added a comment in the docstring, but a few reasons:
- primarily so you don't have to interact with the Service actor, which IMO can be annoying
- pairs the proc_mesh with the Service actor
- later we might want to pass a reference to the service to other actors, without moving where it's placed. This doubles as a handle so we can make calls to it
src/forge/controller/service.py
Outdated
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.
moved to ServiceInterface
This diff makes a few changes:
_call
,__initialize__
,_call_all
(enqueue on all healthy replicas) ,start_session
,get_metrics
,get_metrics_summary
,terminate_session
,stop
, into endpointschoose()
: run this endpoint on a replicacall()
: run this endpoint on all replicassess_id
is an arg. Turns it into akwarg
cc @joecummings