-
Notifications
You must be signed in to change notification settings - Fork 11
Closed
Description
General description
a router is a sync function that retrieves endPoint from the registry.
if it doesn't find any endpoint then it returns null.
changing the router to be async will mean that normal routers will resolve immediately with null or endPoint.
but now, it will be possible to create routers that will be able to wait until the endPoint is available.
API
Design proposition
A clear and concise description of the design proposition.
-
Is backward compatible
-
Changes existing API
Pull Request
[Link]
Old API
Code snippet
export type Router = (options: RouterOptions) => Endpoint | null;
New API
Code snippet
export type Router = (options: RouterOptions) => Promise<Endpoint>;
Test cases
all old tests should pass.
router tests should be modified to run async
Ready for implementation
-
API has been approved
-
Test cases have been prepared
-
Discussed with Technical lead
Definition of Done
-
Developer review
-
All tests are implemented
-
Documentation
Metadata
Metadata
Assignees
Labels
No labels