-
Notifications
You must be signed in to change notification settings - Fork 0
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
feat: implement EboActor.onRequestFinalized handler #23
Conversation
GRT-84 Implement onFinalizeRequest
Actors should handle the event This handler should:
|
export interface RequestFinalizable { | ||
requestId: string; | ||
} | ||
|
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.
Deleting stuff related to RequestFinalizable
, as this case will be handled by the agent's periodic checks; not event related.
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.
just one comment, everything else lgtm 🫡
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.
wdyt about having the callback function as parameter of the onRequestFinalized
instead of the constructor?
it will make it obvious that the function will be called from there
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.
That's a great proposal, you got me thinking why did I go for this option lol 🤔
=== PR #24 spoiler ahead ===
There are some situations in which that onTerminate
callback is being used outside the onRequestFinalized
handler (eg the request was "escalated", so the agent stops tracking it as it will be handled by another system outside the EBO agent)
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.
same comment, everything else looks good
🤖 Linear
Closes GRT-84
Description
Handle the
RequestFinalized
event. It simply terminates theEboActor
and executes a callback that can be used by theEboProcessor
to remove the request from theMap<requestId, EboActor>
.