update

package
v2.2.6+incompatible Latest Latest
Warning

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

Go to latest
Published: Apr 20, 2021 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Overview

Package update is a generated protocol buffer package.

It is generated from these files:

update.proto

It has these top-level messages:

Package
ApplyUpdateRequest
ApplyUpdateResponse
UpdateRequest
UpdateResponse
PublishPackageRequest
PublishPackageResponse
ListPackagesRequest
ListPackagesResponse
DeletePackageRequest
DeletePackageResponse

Package update is a generated protocol buffer package.

It is generated from these files:

update.proto

It has these top-level messages:

Package
ApplyUpdateRequest
ApplyUpdateResponse
UpdateRequest
UpdateResponse
PublishPackageRequest
PublishPackageResponse
ListPackagesRequest
ListPackagesResponse
DeletePackageRequest
DeletePackageResponse

Index

Constants

This section is empty.

Variables

View Source
var Package_PackageStatus_name = map[int32]string{
	0: "Draft",
	1: "Pending",
	2: "Released",
}
View Source
var Package_PackageStatus_value = map[string]int32{
	"Draft":    0,
	"Pending":  1,
	"Released": 2,
}

Functions

func RegisterUpdateServerServiceHandler

func RegisterUpdateServerServiceHandler(s server.Server, hdlr UpdateServerServiceHandler, opts ...server.HandlerOption)

func RegisterUpdateServiceHandler

func RegisterUpdateServiceHandler(s server.Server, hdlr UpdateServiceHandler, opts ...server.HandlerOption)

Types

type ApplyUpdateRequest

type ApplyUpdateRequest struct {
	// Version of the target binary
	TargetVersion string `protobuf:"bytes,1,opt,name=TargetVersion" json:"TargetVersion,omitempty"`
	// Name of the package if it's not the same as the current binary
	PackageName string `protobuf:"bytes,2,opt,name=PackageName" json:"PackageName,omitempty"`
}

func (*ApplyUpdateRequest) Descriptor

func (*ApplyUpdateRequest) Descriptor() ([]byte, []int)

func (*ApplyUpdateRequest) GetPackageName

func (m *ApplyUpdateRequest) GetPackageName() string

func (*ApplyUpdateRequest) GetTargetVersion

func (m *ApplyUpdateRequest) GetTargetVersion() string

func (*ApplyUpdateRequest) ProtoMessage

func (*ApplyUpdateRequest) ProtoMessage()

func (*ApplyUpdateRequest) Reset

func (m *ApplyUpdateRequest) Reset()

func (*ApplyUpdateRequest) String

func (m *ApplyUpdateRequest) String() string

func (*ApplyUpdateRequest) Validate

func (this *ApplyUpdateRequest) Validate() error

type ApplyUpdateResponse

type ApplyUpdateResponse struct {
	Success bool   `protobuf:"varint,1,opt,name=Success" json:"Success,omitempty"`
	Message string `protobuf:"bytes,2,opt,name=Message" json:"Message,omitempty"`
}

func (*ApplyUpdateResponse) Descriptor

func (*ApplyUpdateResponse) Descriptor() ([]byte, []int)

func (*ApplyUpdateResponse) GetMessage

func (m *ApplyUpdateResponse) GetMessage() string

func (*ApplyUpdateResponse) GetSuccess

func (m *ApplyUpdateResponse) GetSuccess() bool

func (*ApplyUpdateResponse) ProtoMessage

func (*ApplyUpdateResponse) ProtoMessage()

func (*ApplyUpdateResponse) Reset

func (m *ApplyUpdateResponse) Reset()

func (*ApplyUpdateResponse) String

func (m *ApplyUpdateResponse) String() string

func (*ApplyUpdateResponse) Validate

func (this *ApplyUpdateResponse) Validate() error

type DeletePackageRequest

type DeletePackageRequest struct {
	Channel     string `protobuf:"bytes,1,opt,name=Channel" json:"Channel,omitempty"`
	PackageName string `protobuf:"bytes,2,opt,name=PackageName" json:"PackageName,omitempty"`
	Version     string `protobuf:"bytes,3,opt,name=Version" json:"Version,omitempty"`
	BinaryOS    string `protobuf:"bytes,4,opt,name=BinaryOS" json:"BinaryOS,omitempty"`
	BinaryArch  string `protobuf:"bytes,5,opt,name=BinaryArch" json:"BinaryArch,omitempty"`
}

func (*DeletePackageRequest) Descriptor

func (*DeletePackageRequest) Descriptor() ([]byte, []int)

func (*DeletePackageRequest) GetBinaryArch

func (m *DeletePackageRequest) GetBinaryArch() string

func (*DeletePackageRequest) GetBinaryOS

func (m *DeletePackageRequest) GetBinaryOS() string

func (*DeletePackageRequest) GetChannel

func (m *DeletePackageRequest) GetChannel() string

func (*DeletePackageRequest) GetPackageName

func (m *DeletePackageRequest) GetPackageName() string

func (*DeletePackageRequest) GetVersion

func (m *DeletePackageRequest) GetVersion() string

func (*DeletePackageRequest) ProtoMessage

func (*DeletePackageRequest) ProtoMessage()

func (*DeletePackageRequest) Reset

func (m *DeletePackageRequest) Reset()

func (*DeletePackageRequest) String

func (m *DeletePackageRequest) String() string

func (*DeletePackageRequest) Validate

func (this *DeletePackageRequest) Validate() error

type DeletePackageResponse

type DeletePackageResponse struct {
	Success bool `protobuf:"varint,2,opt,name=Success" json:"Success,omitempty"`
}

func (*DeletePackageResponse) Descriptor

func (*DeletePackageResponse) Descriptor() ([]byte, []int)

func (*DeletePackageResponse) GetSuccess

func (m *DeletePackageResponse) GetSuccess() bool

func (*DeletePackageResponse) ProtoMessage

func (*DeletePackageResponse) ProtoMessage()

func (*DeletePackageResponse) Reset

func (m *DeletePackageResponse) Reset()

func (*DeletePackageResponse) String

func (m *DeletePackageResponse) String() string

func (*DeletePackageResponse) Validate

func (this *DeletePackageResponse) Validate() error

type ListPackagesRequest

type ListPackagesRequest struct {
	Channel     string `protobuf:"bytes,1,opt,name=Channel" json:"Channel,omitempty"`
	PackageName string `protobuf:"bytes,2,opt,name=PackageName" json:"PackageName,omitempty"`
}

func (*ListPackagesRequest) Descriptor

func (*ListPackagesRequest) Descriptor() ([]byte, []int)

func (*ListPackagesRequest) GetChannel

func (m *ListPackagesRequest) GetChannel() string

func (*ListPackagesRequest) GetPackageName

func (m *ListPackagesRequest) GetPackageName() string

func (*ListPackagesRequest) ProtoMessage

func (*ListPackagesRequest) ProtoMessage()

func (*ListPackagesRequest) Reset

func (m *ListPackagesRequest) Reset()

func (*ListPackagesRequest) String

func (m *ListPackagesRequest) String() string

func (*ListPackagesRequest) Validate

func (this *ListPackagesRequest) Validate() error

type ListPackagesResponse

type ListPackagesResponse struct {
	Packages []*Package `protobuf:"bytes,1,rep,name=Packages" json:"Packages,omitempty"`
}

func (*ListPackagesResponse) Descriptor

func (*ListPackagesResponse) Descriptor() ([]byte, []int)

func (*ListPackagesResponse) GetPackages

func (m *ListPackagesResponse) GetPackages() []*Package

func (*ListPackagesResponse) ProtoMessage

func (*ListPackagesResponse) ProtoMessage()

func (*ListPackagesResponse) Reset

func (m *ListPackagesResponse) Reset()

func (*ListPackagesResponse) String

func (m *ListPackagesResponse) String() string

func (*ListPackagesResponse) Validate

func (this *ListPackagesResponse) Validate() error

type Package

type Package struct {
	// Name of the application
	PackageName string `protobuf:"bytes,1,opt,name=PackageName" json:"PackageName,omitempty"`
	// Version of this new binary
	Version string `protobuf:"bytes,2,opt,name=Version" json:"Version,omitempty"`
	// Release date of the binary
	ReleaseDate int32 `protobuf:"varint,3,opt,name=ReleaseDate" json:"ReleaseDate,omitempty"`
	// Short human-readable description
	Label string `protobuf:"bytes,4,opt,name=Label" json:"Label,omitempty"`
	// Long human-readable description (markdown)
	Description string `protobuf:"bytes,5,opt,name=Description" json:"Description,omitempty"`
	// List or public URL of change logs
	ChangeLog string `protobuf:"bytes,6,opt,name=ChangeLog" json:"ChangeLog,omitempty"`
	// License of this package
	License string `protobuf:"bytes,16,opt,name=License" json:"License,omitempty"`
	// Https URL where to download the binary
	BinaryURL string `protobuf:"bytes,7,opt,name=BinaryURL" json:"BinaryURL,omitempty"`
	// Checksum of the binary to verify its integrity
	BinaryChecksum string `protobuf:"bytes,8,opt,name=BinaryChecksum" json:"BinaryChecksum,omitempty"`
	// Signature of the binary
	BinarySignature string `protobuf:"bytes,9,opt,name=BinarySignature" json:"BinarySignature,omitempty"`
	// Hash type used for the signature
	BinaryHashType string `protobuf:"bytes,10,opt,name=BinaryHashType" json:"BinaryHashType,omitempty"`
	// Size of the binary to download
	BinarySize int64 `protobuf:"varint,15,opt,name=BinarySize" json:"BinarySize,omitempty"`
	// GOOS value used at build time
	BinaryOS string `protobuf:"bytes,17,opt,name=BinaryOS" json:"BinaryOS,omitempty"`
	// GOARCH value used at build time
	BinaryArch string `protobuf:"bytes,18,opt,name=BinaryArch" json:"BinaryArch,omitempty"`
	// Not used : if binary is a patch
	IsPatch bool `protobuf:"varint,11,opt,name=IsPatch" json:"IsPatch,omitempty"`
	// Not used : if a patch, how to patch (bsdiff support)
	PatchAlgorithm string `protobuf:"bytes,12,opt,name=PatchAlgorithm" json:"PatchAlgorithm,omitempty"`
	// Not used : at a point we may deliver services only updates
	ServiceName string                `protobuf:"bytes,13,opt,name=ServiceName" json:"ServiceName,omitempty"`
	Status      Package_PackageStatus `protobuf:"varint,14,opt,name=Status,enum=update.Package_PackageStatus" json:"Status,omitempty"`
}

func (*Package) Descriptor

func (*Package) Descriptor() ([]byte, []int)

func (*Package) GetBinaryArch

func (m *Package) GetBinaryArch() string

func (*Package) GetBinaryChecksum

func (m *Package) GetBinaryChecksum() string

func (*Package) GetBinaryHashType

func (m *Package) GetBinaryHashType() string

func (*Package) GetBinaryOS

func (m *Package) GetBinaryOS() string

func (*Package) GetBinarySignature

func (m *Package) GetBinarySignature() string

func (*Package) GetBinarySize

func (m *Package) GetBinarySize() int64

func (*Package) GetBinaryURL

func (m *Package) GetBinaryURL() string

func (*Package) GetChangeLog

func (m *Package) GetChangeLog() string

func (*Package) GetDescription

func (m *Package) GetDescription() string

func (*Package) GetIsPatch

func (m *Package) GetIsPatch() bool

func (*Package) GetLabel

func (m *Package) GetLabel() string

func (*Package) GetLicense

func (m *Package) GetLicense() string

func (*Package) GetPackageName

func (m *Package) GetPackageName() string

func (*Package) GetPatchAlgorithm

func (m *Package) GetPatchAlgorithm() string

func (*Package) GetReleaseDate

func (m *Package) GetReleaseDate() int32

func (*Package) GetServiceName

func (m *Package) GetServiceName() string

func (*Package) GetStatus

func (m *Package) GetStatus() Package_PackageStatus

func (*Package) GetVersion

func (m *Package) GetVersion() string

func (*Package) ProtoMessage

func (*Package) ProtoMessage()

func (*Package) Reset

func (m *Package) Reset()

func (*Package) String

func (m *Package) String() string

func (*Package) Validate

func (this *Package) Validate() error

type Package_PackageStatus

type Package_PackageStatus int32
const (
	Package_Draft    Package_PackageStatus = 0
	Package_Pending  Package_PackageStatus = 1
	Package_Released Package_PackageStatus = 2
)

func (Package_PackageStatus) EnumDescriptor

func (Package_PackageStatus) EnumDescriptor() ([]byte, []int)

func (Package_PackageStatus) String

func (x Package_PackageStatus) String() string

type PublishPackageRequest

type PublishPackageRequest struct {
	Channel string   `protobuf:"bytes,1,opt,name=Channel" json:"Channel,omitempty"`
	Package *Package `protobuf:"bytes,2,opt,name=Package" json:"Package,omitempty"`
	// Used internally to map to an existing file
	Node *tree.Node `protobuf:"bytes,3,opt,name=Node" json:"Node,omitempty"`
}

func (*PublishPackageRequest) Descriptor

func (*PublishPackageRequest) Descriptor() ([]byte, []int)

func (*PublishPackageRequest) GetChannel

func (m *PublishPackageRequest) GetChannel() string

func (*PublishPackageRequest) GetNode

func (m *PublishPackageRequest) GetNode() *tree.Node

func (*PublishPackageRequest) GetPackage

func (m *PublishPackageRequest) GetPackage() *Package

func (*PublishPackageRequest) ProtoMessage

func (*PublishPackageRequest) ProtoMessage()

func (*PublishPackageRequest) Reset

func (m *PublishPackageRequest) Reset()

func (*PublishPackageRequest) String

func (m *PublishPackageRequest) String() string

func (*PublishPackageRequest) Validate

func (this *PublishPackageRequest) Validate() error

type PublishPackageResponse

type PublishPackageResponse struct {
	Success bool     `protobuf:"varint,1,opt,name=Success" json:"Success,omitempty"`
	Package *Package `protobuf:"bytes,2,opt,name=Package" json:"Package,omitempty"`
}

func (*PublishPackageResponse) Descriptor

func (*PublishPackageResponse) Descriptor() ([]byte, []int)

func (*PublishPackageResponse) GetPackage

func (m *PublishPackageResponse) GetPackage() *Package

func (*PublishPackageResponse) GetSuccess

func (m *PublishPackageResponse) GetSuccess() bool

func (*PublishPackageResponse) ProtoMessage

func (*PublishPackageResponse) ProtoMessage()

func (*PublishPackageResponse) Reset

func (m *PublishPackageResponse) Reset()

func (*PublishPackageResponse) String

func (m *PublishPackageResponse) String() string

func (*PublishPackageResponse) Validate

func (this *PublishPackageResponse) Validate() error

type UpdateRequest

type UpdateRequest struct {
	// Channel name
	Channel string `protobuf:"bytes,1,opt,name=Channel" json:"Channel,omitempty"`
	// Name of the currently running application
	PackageName string `protobuf:"bytes,2,opt,name=PackageName" json:"PackageName,omitempty"`
	// Current version of the application
	CurrentVersion string `protobuf:"bytes,3,opt,name=CurrentVersion" json:"CurrentVersion,omitempty"`
	// Current GOOS
	GOOS string `protobuf:"bytes,4,opt,name=GOOS" json:"GOOS,omitempty"`
	// Current GOARCH
	GOARCH string `protobuf:"bytes,5,opt,name=GOARCH" json:"GOARCH,omitempty"`
	// Not Used : specific service to get updates for
	ServiceName string `protobuf:"bytes,6,opt,name=ServiceName" json:"ServiceName,omitempty"`
	// For enterprise version, info about the current license
	LicenseInfo map[string]string `` /* 142-byte string literal not displayed */
}

func (*UpdateRequest) Descriptor

func (*UpdateRequest) Descriptor() ([]byte, []int)

func (*UpdateRequest) GetChannel

func (m *UpdateRequest) GetChannel() string

func (*UpdateRequest) GetCurrentVersion

func (m *UpdateRequest) GetCurrentVersion() string

func (*UpdateRequest) GetGOARCH

func (m *UpdateRequest) GetGOARCH() string

func (*UpdateRequest) GetGOOS

func (m *UpdateRequest) GetGOOS() string

func (*UpdateRequest) GetLicenseInfo

func (m *UpdateRequest) GetLicenseInfo() map[string]string

func (*UpdateRequest) GetPackageName

func (m *UpdateRequest) GetPackageName() string

func (*UpdateRequest) GetServiceName

func (m *UpdateRequest) GetServiceName() string

func (*UpdateRequest) ProtoMessage

func (*UpdateRequest) ProtoMessage()

func (*UpdateRequest) Reset

func (m *UpdateRequest) Reset()

func (*UpdateRequest) String

func (m *UpdateRequest) String() string

func (*UpdateRequest) Validate

func (this *UpdateRequest) Validate() error

type UpdateResponse

type UpdateResponse struct {
	Channel string `protobuf:"bytes,1,opt,name=Channel" json:"Channel,omitempty"`
	// List of available binaries
	AvailableBinaries []*Package `protobuf:"bytes,2,rep,name=AvailableBinaries" json:"AvailableBinaries,omitempty"`
}

func (*UpdateResponse) Descriptor

func (*UpdateResponse) Descriptor() ([]byte, []int)

func (*UpdateResponse) GetAvailableBinaries

func (m *UpdateResponse) GetAvailableBinaries() []*Package

func (*UpdateResponse) GetChannel

func (m *UpdateResponse) GetChannel() string

func (*UpdateResponse) ProtoMessage

func (*UpdateResponse) ProtoMessage()

func (*UpdateResponse) Reset

func (m *UpdateResponse) Reset()

func (*UpdateResponse) String

func (m *UpdateResponse) String() string

func (*UpdateResponse) Validate

func (this *UpdateResponse) Validate() error

type UpdateServerService

type UpdateServerService struct {
	UpdateServerServiceHandler
}

func (*UpdateServerService) CheckForUpdate

func (h *UpdateServerService) CheckForUpdate(ctx context.Context, in *UpdateRequest, out *UpdateResponse) error

func (*UpdateServerService) DeletePackage

func (*UpdateServerService) ListPackages

func (*UpdateServerService) PublishPackage

type UpdateServerServiceClient

type UpdateServerServiceClient interface {
	// Ask the update server if there are any available updates
	CheckForUpdate(ctx context.Context, in *UpdateRequest, opts ...client.CallOption) (*UpdateResponse, error)
	PublishPackage(ctx context.Context, in *PublishPackageRequest, opts ...client.CallOption) (*PublishPackageResponse, error)
	ListPackages(ctx context.Context, in *ListPackagesRequest, opts ...client.CallOption) (*ListPackagesResponse, error)
	DeletePackage(ctx context.Context, in *DeletePackageRequest, opts ...client.CallOption) (*DeletePackageResponse, error)
}

func NewUpdateServerServiceClient

func NewUpdateServerServiceClient(serviceName string, c client.Client) UpdateServerServiceClient

type UpdateServerServiceHandler

type UpdateServerServiceHandler interface {
	// Ask the update server if there are any available updates
	CheckForUpdate(context.Context, *UpdateRequest, *UpdateResponse) error
	PublishPackage(context.Context, *PublishPackageRequest, *PublishPackageResponse) error
	ListPackages(context.Context, *ListPackagesRequest, *ListPackagesResponse) error
	DeletePackage(context.Context, *DeletePackageRequest, *DeletePackageResponse) error
}

type UpdateService

type UpdateService struct {
	UpdateServiceHandler
}

func (*UpdateService) ApplyUpdate

func (*UpdateService) UpdateRequired

func (h *UpdateService) UpdateRequired(ctx context.Context, in *UpdateRequest, out *UpdateResponse) error

type UpdateServiceClient

type UpdateServiceClient interface {
	UpdateRequired(ctx context.Context, in *UpdateRequest, opts ...client.CallOption) (*UpdateResponse, error)
	ApplyUpdate(ctx context.Context, in *ApplyUpdateRequest, opts ...client.CallOption) (*ApplyUpdateResponse, error)
}

func NewUpdateServiceClient

func NewUpdateServiceClient(serviceName string, c client.Client) UpdateServiceClient

type UpdateServiceHandler

type UpdateServiceHandler interface {
	UpdateRequired(context.Context, *UpdateRequest, *UpdateResponse) error
	ApplyUpdate(context.Context, *ApplyUpdateRequest, *ApplyUpdateResponse) error
}

Jump to

Keyboard shortcuts

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