Skip to main content

Module clients.h2o_engine_profile.h2o_engine_profile

Functions

from_api_object

def from_api_object(api_object: h2o_engine_manager.gen.model.v1_h2_o_engine_profile.V1H2OEngineProfile) ‑> H2OEngineProfile

Classes

H2OEngineProfile

class H2OEngineProfile(node_count_constraint: h2o_engine_manager.clients.constraint.profile_constraint_numeric.ProfileConstraintNumeric, cpu_constraint: h2o_engine_manager.clients.constraint.profile_constraint_numeric.ProfileConstraintNumeric, gpu_constraint: h2o_engine_manager.clients.constraint.profile_constraint_numeric.ProfileConstraintNumeric, memory_bytes_constraint: h2o_engine_manager.clients.constraint.profile_constraint_numeric.ProfileConstraintNumeric, max_idle_duration_constraint: h2o_engine_manager.clients.constraint.profile_constraint_duration.ProfileConstraintDuration, max_running_duration_constraint: h2o_engine_manager.clients.constraint.profile_constraint_duration.ProfileConstraintDuration, name: str = '', display_name: str = '', priority: int = 0, enabled: bool = True, assigned_oidc_roles_enabled: bool = True, assigned_oidc_roles: Optional[List[str]] = None, max_running_engines: Optional[int] = None, yaml_pod_template_spec: str = '', yaml_gpu_tolerations: str = '', create_time: Optional[datetime.datetime] = None, update_time: Optional[datetime.datetime] = None, creator: str = '', updater: str = '', creator_display_name: str = '', updater_display_name: str = '')

H2OEngineProfile represents a set of values that are used for H2OEngine.

H2OEngineProfile represents a set of values that are used for H2OEngine.

Args
node_count_constraint
Constraint for each H2OEngine's node count that uses this profile.
cpu_constraint
Constraint for each H2OEngine's cpu that uses this profile.
gpu_constraint
Constraint for each H2OEngine's gpu that uses this profile.
memory_bytes_constraint
Constraint for each H2OEngine's memory_bytes that uses this profile.
max_idle_duration_constraint
Constraint for each H2OEngine's max_idle_duration that uses this profile.
max_running_duration_constraint
Constraint for each H2OEngine's max_running_duration that uses this profile.
name
Resource name. Format "workspaces//h2oEngineProfiles/".
display_name
Human-readable name.
priority
Priority of the H2OEngineProfile. Lower value means higher priority. Priority is NOT a unique value (any two H2OEngineProfiles can have the same priority value).
enabled
When set to true, the H2OEngineProfile is enabled and can be used in H2OEngine. When set to false, the H2OEngineProfile is disabled and cannot be used in any H2OEngine.
assigned_oidc_roles_enabled
When set to true, the assigned_oidc_roles field is verified when a user uses this profile.
assigned_oidc_roles
List of OIDC roles assigned to this H2OEngineProfile. When profile has assigned some OIDC roles and verification of this list is enabled (assigned_oidc_roles_enabled=true), then this profile can be used only by users who have assigned at least one role from this list.
max_running_engines
Maximum number of H2OEngines per user that can be running when using this H2OEngineProfile.
yaml_pod_template_spec
YAML representation of custom PodTemplateSpec. Definition of PodTemplateSpec: https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#podtemplatespec-v1-coreWhen specified, then it is applied for each H2OEngine that uses this profile. PodTemplateSpec describes what will be applied on top of a regular H2O pod before it is created. This template is merged into H2O default pod using StrategicMergePatch method (it overrides the default pod). More info about StrategicMergePatch: https://kubernetes.io/docs/tasks/manage-kubernetes-objects/update-api-object-kubectl-patch/
yaml_gpu_tolerations
YAML representation of custom GPU Tolerations. Definition of one Toleration: https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#toleration-v1-coreWhen specified, then it is applied for each H2OEngine that uses this profile. GPUTolerations sets H2O's pod.spec.tolerations in case H2OEngine has GPU > 0. This will override any tolerations defined in yaml_pod_template_spec.PodSpec.Tolerations field.
create_time
Time when the H2OEngineProfile was created.
update_time
Time when the H2OEngineProfile was last updated.
creator
Name of entity that created the H2OEngineProfile.
updater
Name of entity that last updated the H2OEngineProfile.
creator_display_name
Human-readable name of entity that created the H2OEngineProfile.
updater_display_name
Human-readable name of entity that last updated the H2OEngineProfile.

Methods

to_api_object

def to_api_object(self) ‑> h2o_engine_manager.gen.model.v1_h2_o_engine_profile.V1H2OEngineProfile

to_resource

def to_resource(self) ‑> h2o_engine_manager.gen.model.required_h2_o_engine_profile_resource.RequiredH2OEngineProfileResource

Feedback