birdwatcherservice

package
v0.0.0-...-0117b6e Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: Apache-2.0 Imports: 17 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(context context.T, pkgArchive archive.IPackageArchive, facadeClient facade.BirdwatcherFacade, manifestCache packageservice.ManifestCache, name string) packageservice.PackageService

New constructor for PackageService

func NewBirdwatcherArchive

func NewBirdwatcherArchive(ctx context.T, facadeClient facade.BirdwatcherFacade, manifestCache packageservice.ManifestCache, context map[string]string) packageservice.PackageService

func NewDocumentArchive

func NewDocumentArchive(context context.T, facadeClient facade.BirdwatcherFacade, manifestCache packageservice.ManifestCache) packageservice.PackageService

Types

type NanoTime

type NanoTime interface {
	NowUnixNano() int64
}

NanoTime is helper interface for mocking time

type PackageService

type PackageService struct {
	Context context.T
	// contains filtered or unexported fields
}

PackageService is the concrete type for Birdwatcher PackageService

func (*PackageService) DownloadArtifact

func (ds *PackageService) DownloadArtifact(tracer trace.Tracer, packageName string, version string) (string, error)

DownloadArtifact downloads the platform matching artifact specified in the manifest

func (*PackageService) DownloadManifest

func (ds *PackageService) DownloadManifest(tracer trace.Tracer, packageName string, version string) (string, string, bool, error)

DownloadManifest downloads the manifest for a given version (or latest) and returns the agent version specified in manifest

func (*PackageService) GetPackageArnAndVersion

func (ds *PackageService) GetPackageArnAndVersion(packageName string, packageVersion string) (name string, version string)

func (*PackageService) PackageServiceName

func (ds *PackageService) PackageServiceName() string

func (*PackageService) ReportResult

func (ds *PackageService) ReportResult(tracer trace.Tracer, result packageservice.PackageResult) error

ReportResult sents back the result of the install/upgrade/uninstall run back to Birdwatcher

type TimeImpl

type TimeImpl struct {
}

func (*TimeImpl) NowUnixNano

func (t *TimeImpl) NowUnixNano() int64

Jump to

Keyboard shortcuts

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