class documentation
class _InstrumentedReceiver(_TokenReceiver): (source)
Constructor: _InstrumentedReceiver(receiver, metrics)
Undocumented
| Method | __init__ |
Undocumented |
| Method | can |
Delegate retry decisions to the wrapped receiver. |
| Async Method | fetch |
Fetch a token and record the result. |
| Property | latest |
Return the wrapped receiver's latest token. |
| Async Method | _fetch |
Low-level asynchronous fetch implementation. |
| Instance Variable | _attempt |
Undocumented |
| Instance Variable | _metrics |
Undocumented |
| Instance Variable | _receiver |
Undocumented |
Inherited from Receiver:
| Instance Variable | _latest |
The most recently fetched token, or None if no token has been fetched yet. Implementations may update this to support inspection or caching by callers. |
async def fetch(self, timeout:
float | None = None, options: dict[ str, str] | None = None) -> _Token:
(source)
¶
overrides
nebius.aio.token.token.Receiver.fetchFetch a token and record the result.
async def _fetch(self, timeout:
float | None = None, options: dict[ str, str] | None = None) -> _Token:
(source)
¶
overrides
nebius.aio.token.token.Receiver._fetchLow-level asynchronous fetch implementation.
Subclasses must implement this method to perform the actual token
retrieval. This method is intentionally prefixed with an underscore to
indicate it is the minimal primitive; callers should use
fetch which records the result in _latest.
| Parameters | |
timeout:optional float | Optional timeout in seconds for the fetch operation. |
| options:optional dict[str, str] | Optional implementation-specific options forwarded by the request layer. |
| Returns | |
Token | A freshly fetched Token. |