Documentation
¶
Index ¶
- Constants
- func CancelReservationBestEffort(ctx context.Context, svc *service.Service, logger *slog.Logger, ...)
- func CapacityRequestFromCreate(req models.CreateSandboxRequest) capacity.Request
- func CreateOnSelectedNode(ctx context.Context, svc *service.Service, logger *slog.Logger, ...) (*models.CreateSandboxResponse, error)
- func DeletePlacementBestEffort(ctx context.Context, svc *service.Service, logger *slog.Logger, ...)
- type CreateOptions
- type Decision
- type ErrorWriter
- type PrepareOptions
Constants ¶
View Source
const ( HeaderTarget = "X-Cluster-Create-Target" HeaderID = "X-Cluster-Create-ID" ReservationTTL = 120 * time.Second )
Variables ¶
This section is empty.
Functions ¶
func CapacityRequestFromCreate ¶
func CapacityRequestFromCreate(req models.CreateSandboxRequest) capacity.Request
func CreateOnSelectedNode ¶
func CreateOnSelectedNode(ctx context.Context, svc *service.Service, logger *slog.Logger, req models.CreateSandboxRequest, reservationID string, opts CreateOptions) (*models.CreateSandboxResponse, error)
Types ¶
type CreateOptions ¶
type CreateOptions struct {
PromoteWithSpec bool
}
type Decision ¶
type Decision struct {
ReservationID string
}
func Prepare ¶
func Prepare(w http.ResponseWriter, r *http.Request, svc *service.Service, req models.CreateSandboxRequest, writeError ErrorWriter, opts PrepareOptions) (Decision, bool)
type ErrorWriter ¶
type ErrorWriter func(w http.ResponseWriter, status int, message string)
type PrepareOptions ¶
type PrepareOptions struct {
PreferredSandboxID string
}
Click to show internal directories.
Click to hide internal directories.