Skip to content

Pass controller runtime objects with Context

Hossein Pursultani requested to merge hp-runtime-context into master

This MR introduces runtime context where runtime object of Controller, for example the Client, are embedded in the Context.

This make it easier to pass down the request-scoped information to other components.

The following are included:

  • ContextBuilder type for building a new runtime context with the Client, Logger, etc.
  • ClientFromContext function to retrieve the Client from a context.
  • RecorderFromContext function to retrieve the EventRecorder from a context.

Related to #889 (closed)

Closes #440 (closed)

Closes #325 (closed)

Edited by Hossein Pursultani

Merge request reports