latest_imports

package
v0.35.0 Latest Latest
Warning

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

Go to latest
Published: Aug 22, 2025 License: Apache-2.0 Imports: 9 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

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

func NewAPI

func NewAPI(client HttpClient, taskWaiter TaskWaiter, logger Log) *API

func (*API) Get

func (a *API) Get(ctx context.Context, subscription int, database int) (*LatestImportStatus, error)

func (*API) GetFixed added in v0.14.1

func (a *API) GetFixed(ctx context.Context, subscription int, database int) (*LatestImportStatus, error)

type Error

type Error struct {
	Type        *string `json:"type,omitempty"`
	Description *string `json:"description,omitempty"`
	Status      *string `json:"status,omitempty"`
}

func (*Error) Error

func (e *Error) Error() string

func (*Error) StatusCode

func (e *Error) StatusCode() string

func (*Error) String

func (e *Error) String() string

type FailureReasonParam added in v0.15.0

type FailureReasonParam struct {
	Key   *string `json:"key,omitempty"`
	Value *string `json:"value,omitempty"`
}

func (FailureReasonParam) String added in v0.15.0

func (o FailureReasonParam) String() string

type HttpClient

type HttpClient interface {
	Get(ctx context.Context, name, path string, responseBody interface{}) error
}

type LatestImportStatus

type LatestImportStatus struct {
	CommandType *string   `json:"commandType,omitempty"`
	Description *string   `json:"description,omitempty"`
	Status      *string   `json:"status,omitempty"`
	ID          *string   `json:"taskId,omitempty"`
	Response    *Response `json:"response,omitempty"`
}

func (LatestImportStatus) String

func (o LatestImportStatus) String() string

type Log

type Log interface {
	Printf(format string, args ...interface{})
}

type NotFound

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

func (*NotFound) Error

func (f *NotFound) Error() string

type Resource added in v0.15.0

type Resource struct {
	Status              *string               `json:"status,omitempty"`
	LastImportTime      *time.Time            `json:"lastImportTime,omitempty"`
	FailureReason       *string               `json:"failureReason,omitempty"`
	FailureReasonParams []*FailureReasonParam `json:"failureReasonParams,omitempty"`
}

func (Resource) String added in v0.15.0

func (o Resource) String() string

type Response

type Response struct {
	ID       *int      `json:"resourceId,omitempty"`
	Resource *Resource `json:"resource,omitempty"`
	Error    *Error    `json:"error,omitempty"`
}

func (Response) String

func (o Response) String() string

type TaskWaiter

type TaskWaiter interface {
	WaitForTask(ctx context.Context, id string) (*internal.Task, error)
}

Jump to

Keyboard shortcuts

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