Documentation ¶
Index ¶
- Constants
- Variables
- func HandleGetEndpoint(a api.HTTPAPI, w http.ResponseWriter, r *http.Request, params map[string]any)
- func NewClusterInitializer(l log.Logger, ytc yt.Client, root ypath.Path) strawberry.ClusterInitializer
- func NewController(l log.Logger, ytc yt.Client, root ypath.Path, cluster string, ...) strawberry.Controller
- type ClusterInitializer
- type Config
- type Controller
- func (c *Controller) DescribeOptions(parsedSpeclet any) []strawberry.OptionGroupDescriptor
- func (c *Controller) Family() string
- func (c *Controller) GetOpBriefAttributes(parsedSpeclet any) map[string]any
- func (c *Controller) ParseSpeclet(specletYson yson.RawValue) (any, error)
- func (c *Controller) Prepare(ctx context.Context, oplet *strawberry.Oplet) (spec map[string]any, description map[string]any, annotations map[string]any, ...)
- func (c *Controller) Root() ypath.Path
- func (c *Controller) UpdateState() (changed bool, err error)
- type GetEndpointResult
- type Speclet
Constants ¶
View Source
const ( DefaultCPU = 2 DefaultMemory = 8 * 1024 * 1024 * 1024 )
View Source
const (
JupytPort = 27042
)
Variables ¶
View Source
var AllCommands = []api.CmdDescriptor{ GetEndpointCmdDescriptor, }
View Source
var GetEndpointCmdDescriptor = api.CmdDescriptor{ Name: "get_endpoint", Parameters: []api.CmdParameter{api.AliasParameter.AsExplicit()}, Description: "get endpoint of JupYT strawberry operation", Handler: HandleGetEndpoint, }
Functions ¶
func HandleGetEndpoint ¶ added in v0.0.9
func NewClusterInitializer ¶ added in v0.0.11
func NewClusterInitializer(l log.Logger, ytc yt.Client, root ypath.Path) strawberry.ClusterInitializer
func NewController ¶
Types ¶
type ClusterInitializer ¶ added in v0.0.11
type ClusterInitializer struct {
// contains filtered or unexported fields
}
func (*ClusterInitializer) ACONamespace ¶ added in v0.0.11
func (initializer *ClusterInitializer) ACONamespace() string
func (*ClusterInitializer) InitializeCluster ¶ added in v0.0.11
func (initializer *ClusterInitializer) InitializeCluster() error
type Controller ¶
type Controller struct {
// contains filtered or unexported fields
}
func (*Controller) DescribeOptions ¶
func (c *Controller) DescribeOptions(parsedSpeclet any) []strawberry.OptionGroupDescriptor
func (*Controller) Family ¶
func (c *Controller) Family() string
func (*Controller) GetOpBriefAttributes ¶
func (c *Controller) GetOpBriefAttributes(parsedSpeclet any) map[string]any
func (*Controller) ParseSpeclet ¶
func (c *Controller) ParseSpeclet(specletYson yson.RawValue) (any, error)
func (*Controller) Root ¶
func (c *Controller) Root() ypath.Path
func (*Controller) UpdateState ¶
func (c *Controller) UpdateState() (changed bool, err error)
type GetEndpointResult ¶ added in v0.0.9
type GetEndpointResult struct { Address string `yson:"address"` OperationID yt.OperationID `yson:"operation_id"` JobID yt.JobID `yson:"job_id"` }
func GetEndpoint ¶ added in v0.0.9
type Speclet ¶
type Speclet struct { CPU *uint64 `yson:"cpu"` Memory *uint64 `yson:"memory"` JupyterDockerImage string `yson:"jupyter_docker_image"` }
func (*Speclet) CPUOrDefault ¶
func (*Speclet) MemoryOrDefault ¶
Click to show internal directories.
Click to hide internal directories.