runtime
Runtime model for Datalayer.
Provides data structures for runtime model in Datalayer.
class RuntimeModel(*, name: str, environment: str = 'python-cpu-env', time_reservation: float = 10.0, run_url: str = 'https://prod1.datalayer.run', iam_url: str | None = None, token: str | None = None, external_token: str | None = None, pod_name: str | None = None, ingress: str | None = None, reservation_id: str | None = None, uid: str | None = None, burning_rate: float | None = None, jupyter_token: str | None = None, started_at: str | None = None, expired_at: str | None = None, runtime: Dict[str, Any] | None = <factory>, kernel_client: Any | None = None, kernel_id: str | None = None, executing: bool = False, url: str = 'https://prod1.datalayer.run', credits_per_second: float = 1, extra: Dict[str, Any] | None = None) -> None
Model representing a Datalayer Runtime configuration and state.
This model encapsulates both the configuration parameters and runtime state for a Datalayer runtime, including resource allocation, time limits, service endpoints, and execution state.
Config()
Pydantic configuration for RuntimeModel.
credits_limit
Calculate the credits limit based on burning rate and time reservation.
Returns
-
Optional[float]
The credits limit, or None if burning_rate is not set.