async

package
v0.0.0-...-2469a1d Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

SPDX-License-Identifier: Apache-2.0 Copyright 2024 Seqera

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

SPDX-License-Identifier: Apache-2.0 Copyright 2024 Seqera

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNoTagsFound       = errors.New("no tags found")
	ErrImageInfoNotFound = errors.New("image info not found")
)

Functions

This section is empty.

Types

type Async

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

Async is a struct that wraps an underlying registry.Client to provide asynchronous methods for interacting with a container registry. It continuously syncs data from the registry in a separate goroutine.

func New

func New(
	client *registryimpl.Registry,
	refreshInterval time.Duration,
	requestsPerSecond int,
) *Async

func (*Async) ImageInfo

func (c *Async) ImageInfo(ctx context.Context, repo string, tag string) (image v1.Image, reference string, err error)

func (*Async) RepoList

func (c *Async) RepoList(ctx context.Context) (repos map[string]registry.RepoData, err error)

func (*Async) Start

func (c *Async) Start(ctx context.Context) error

func (*Async) TagList

func (c *Async) TagList(ctx context.Context, repo string) ([]string, error)

Jump to

Keyboard shortcuts

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