ops

package
v1.17.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 22, 2026 License: Apache-2.0 Imports: 10 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Executor

type Executor struct {
	// contains filtered or unexported fields
}

Executor provides shared ENI operation primitives for both Pool controller (shared ENI) and ENI controller (exclusive ENI)

func NewExecutor

func NewExecutor(aliyun aliyunClient.OpenAPI, tracer trace.Tracer) *Executor

NewExecutor creates a new ENI operation executor

func (*Executor) AttachAndWait

func (e *Executor) AttachAndWait(ctx context.Context, eniID, instanceID, trunkENIID string) (*aliyunClient.NetworkInterface, error)

AttachAndWait attaches ENI and waits for it to be ready (blocking) Used by ENI controller for synchronous ENI attach

func (*Executor) AttachAsync

func (e *Executor) AttachAsync(ctx context.Context, eniID, instanceID, trunkENIID string) error

AttachAsync initiates attach and returns immediately (non-blocking) Used by Pool controller for async ENI attach

func (*Executor) CheckStatus

func (e *Executor) CheckStatus(ctx context.Context, eniID string) (*aliyunClient.NetworkInterface, error)

CheckStatus checks the current status of an ENI

func (*Executor) Delete

func (e *Executor) Delete(ctx context.Context, eniID string) error

Delete deletes an ENI

func (*Executor) DetachAndWait

func (e *Executor) DetachAndWait(ctx context.Context, eniID, instanceID, trunkENIID string) error

DetachAndWait detaches ENI and waits for it to be available (blocking)

func (*Executor) DetachAsync

func (e *Executor) DetachAsync(ctx context.Context, eniID, instanceID, trunkENIID string) error

DetachAsync initiates detach and returns immediately (non-blocking)

func (*Executor) GetInitialDelay

func (e *Executor) GetInitialDelay(ctx context.Context, eniID string) time.Duration

GetInitialDelay returns the initial delay before checking status based on ENI type and backend API.

func (*Executor) GetTimeout

func (e *Executor) GetTimeout(ctx context.Context, eniID string) time.Duration

GetTimeout returns the attach timeout based on ENI type and backend API.

func (*Executor) WaitForStatus

func (e *Executor) WaitForStatus(ctx context.Context, eniID, status string) (*aliyunClient.NetworkInterface, error)

WaitForStatus waits for ENI to reach the specified status

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL