The ComponentInvoker trait is surfaced by Runtime and optionally injected into registered Services via set_invoker. For example, the HTTP Gateway) uses that for any Component-targeting routes.
In addition to the invoke(..) function, ComponentInvoker also provides a get_component(..) function for introspecting the functions and their parameters. Adding a get_components(..) function will allow lookup from Services. This function should accept a Selector for filtering based on selection criteria (e.g. label-matching), or will return all registered Components if None is passed.
The
ComponentInvokertrait is surfaced byRuntimeand optionally injected into registeredServicesviaset_invoker. For example, the HTTP Gateway) uses that for any Component-targeting routes.In addition to the
invoke(..)function,ComponentInvokeralso provides aget_component(..)function for introspecting the functions and their parameters. Adding aget_components(..)function will allow lookup from Services. This function should accept aSelectorfor filtering based on selection criteria (e.g. label-matching), or will return all registered Components ifNoneis passed.