Documentation
¶
Overview ¶
Package servicer is a container for the AndroidProvision state machine.
Index ¶
- type AndroidOS
- type AndroidPackage
- type AndroidService
- func NewAndroidService(dut *lab_api.Dut, dutClient api.DutServiceClient, req *api.InstallRequest) (*AndroidService, error)
- func NewAndroidServiceFromAndroidProvisionRequest(dutClient api.DutServiceClient, req *api.AndroidProvisionRequest) (*AndroidService, error)
- func NewAndroidServiceFromExistingConnection(conn common_utils.ServiceAdapterInterface, dutSerialNumber string, ...) (*AndroidService, error)
- type CIPDPackage
- type DUTConnection
- type ImagePath
- type OsBuildInfo
- type PkgFile
- type ProvisionPackage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AndroidOS ¶
type AndroidOS struct { ImagePath *ImagePath BuildInfo *OsBuildInfo UpdatedBuildInfo *OsBuildInfo }
AndroidOS contains information about Android OS to install.
type AndroidPackage ¶
AndroidPackage contains information about installed Android package.
type AndroidService ¶
type AndroidService struct { DUT *DUTConnection OS *AndroidOS ProvisionPackages []*ProvisionPackage ProvisionDir string }
AndroidService inherits ServiceInterface
func NewAndroidService ¶
func NewAndroidService(dut *lab_api.Dut, dutClient api.DutServiceClient, req *api.InstallRequest) (*AndroidService, error)
func NewAndroidServiceFromAndroidProvisionRequest ¶
func NewAndroidServiceFromAndroidProvisionRequest(dutClient api.DutServiceClient, req *api.AndroidProvisionRequest) (*AndroidService, error)
func NewAndroidServiceFromExistingConnection ¶
func NewAndroidServiceFromExistingConnection(conn common_utils.ServiceAdapterInterface, dutSerialNumber string, osImage *api.AndroidOsImage, pkgProtos []*api.CIPDPackage) (*AndroidService, error)
NewAndroidServiceFromExistingConnection utilizes a given ServiceAdapter. Generally useful for tests.
func (*AndroidService) CleanupOnFailure ¶
func (svc *AndroidService) CleanupOnFailure(states []common_utils.ServiceState, executionErr error) error
CleanupOnFailure is called if one of service's states failes to Execute() and should clean up the temporary files, and undo the execution, if feasible.
func (*AndroidService) MarshalResponseMetadata ¶
func (svc *AndroidService) MarshalResponseMetadata() (*anypb.Any, error)
MarshalResponseMetadata packs AndroidProvisionResponseMetadata into the Any message type.
func (*AndroidService) UnmarshalRequestMetadata ¶
func (svc *AndroidService) UnmarshalRequestMetadata(req *api.InstallRequest) error
UnmarshalRequestMetadata unpacks the Any metadata field into AndroidProvisionRequestMetadata
type CIPDPackage ¶
type CIPDPackage struct { PackageProto *api.CIPDPackage FilePath string PackageName string InstanceId string VersionCode string }
CIPDPackage wraps CIPD package proto and contains the resolved CIPD package info.
type DUTConnection ¶
type DUTConnection struct { AssociatedHost common_utils.ServiceAdapterInterface SerialNumber string Board string }
DUTConnection has information about CrosDUT connection and DUT serial number.
type ImagePath ¶
type ImagePath struct { GsPath string BoardToBuildID map[string]string Files []string // DUT directory containing the binary images. DutAndroidProductOut string }
ImagePath defines OS image file(s) to flash.
type OsBuildInfo ¶
OsBuildInfo contains information about Android OS build.
type ProvisionPackage ¶
type ProvisionPackage struct { AndroidPackage *AndroidPackage CIPDPackage *CIPDPackage APKFile *PkgFile }
ProvisionPackage contains information about provision package.