Documentation
¶
Overview ¶
Package gateway reads the aggregate usage report a forwarding gateway publishes for the upstream accounts it brokers.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ReadRoutes ¶
func ReadRoutes(ctx context.Context, transport http.RoundTripper, resolve func(context.Context) ([]Route, error), providerID string, fallback wire.AccountUsageResponse) (wire.AccountUsageResponse, error)
ReadRoutes asks each route for the provider's section in order and answers with the first that covers it. A route without an http base or a bearer is skipped. The resolver rechecks the native routes after every read; a changed binding discards the observation. When no route covers the provider, fallback answers.
Types ¶
Click to show internal directories.
Click to hide internal directories.