Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NormalizeTime ¶
NormalizeTime converts timeout values to the precision Kubernetes persists and E2B exposes: wall-clock time at whole-second precision in UTC. This removes Go's monotonic clock reading, drops sub-second differences, and normalizes the Location so timeout comparison and retry conflict handling stay stable across in-memory values, metav1.Time serialization, and API server round trips.
func ShouldExtendTimeout ¶
ShouldExtendTimeout reports whether requested extends the effective end time.
Types ¶
type Options ¶
type Options struct {
ShutdownTime time.Time
PauseTime time.Time
// Baseline is the timeout state the caller observed before issuing this update.
// Consulted only when the policy passed to SaveTimeoutWithPolicy is BaselineAware.
Baseline *Options `json:"-"`
}
Options is the time when Sandbox will be shut down or paused. Zero means never.
func GetTimeoutFromSandbox ¶
func GetTimeoutFromSandbox(sbx *agentsv1alpha1.Sandbox) Options
type UpdatePolicy ¶
type UpdatePolicy string
const ( UpdatePolicyAlways UpdatePolicy = "Always" UpdatePolicyExtendOnly UpdatePolicy = "ExtendOnly" UpdatePolicyBaselineAware UpdatePolicy = "BaselineAware" )
Click to show internal directories.
Click to hide internal directories.