model

package
v0.0.0-...-028f1de Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ACSInstanceInformation is inventory type of instance information
	ACSInstanceInformation = "ACS:InstanceInformation"
	// Enabled represents constant string used to enable various components of inventory plugin
	Enabled = "Enabled"
	// ErrorThreshold represents error threshold for inventory plugin
	ErrorThreshold = 10
	// InventoryPolicyDocName represents name of inventory policy doc
	InventoryPolicyDocName = "policy.json"
	// SizeLimitKBPerInventoryType represents size limit in KB for 1 inventory data type
	// Bump up to 3MB for agent. We have more strict size limit rule in the micro service.
	SizeLimitKBPerInventoryType = 3072
	// TotalSizeLimitKB represents size limit in KB for 1 PutInventory API call
	TotalSizeLimitKB = 10240
	// Standard name for 64-bit architecture
	Arch64Bit = "x86_64"
	// Standard name for 32-bit architecture
	Arch32Bit = "i386"
)

Variables

This section is empty.

Functions

func FormatArchitecture

func FormatArchitecture(arch string) string

FormatArchitecture converts different architecture values to the standard inventory value

Types

type ApplicationData

type ApplicationData struct {
	ApplicationType string `json:",omitempty"`
	Architecture    string
	Epoch           string `json:",omitempty"`
	InstalledTime   string `json:",omitempty"`
	Name            string
	PackageId       string `json:",omitempty"`
	Publisher       string
	Release         string `json:",omitempty"`
	Summary         string `json:",omitempty"`
	URL             string `json:",omitempty"`
	Version         string
}

ApplicationData captures all attributes present in ACS:Application inventory type

type Config

type Config struct {
	Collection string `json:"Collection"`
	Filters    string `json:"Filters"`
	Location   string `json:"Location"`
}

type FileData

type FileData struct {
	CompanyName      string
	Description      string
	FileVersion      string
	InstalledDate    string
	InstalledDir     string
	LastAccessTime   string
	ModificationTime string
	Name             string
	ProductLanguage  string
	ProductName      string
	ProductVersion   string
	Size             string
}

FileData captures all attributes present in ACS:File inventory type

type InstanceDetailedInformation

type InstanceDetailedInformation struct {
	CPUCores              string
	CPUHyperThreadEnabled string
	CPUModel              string
	CPUSockets            string
	CPUSpeedMHz           string
	CPUs                  string
	OSServicePack         string
}

InstanceDetailedInformation captures all attributes present in ACS:InstanceDetailedInformation inventory type

type InstanceInformation

type InstanceInformation struct {
	AgentName       string
	AgentVersion    string
	ComputerName    string
	PlatformName    string
	PlatformType    string
	PlatformVersion string
	InstanceId      string
	IpAddress       string
	ResourceType    string
	RamRole         string
}

InstanceInformation captures all attributes present in ACS:InstanceInformation inventory type

type InventoryItem

type InventoryItem struct {
	// CaptureTime is a required field
	CaptureTime *string `type:"string" required:"true"`

	// The inventory data of the inventory type.
	Content []map[string]*string `type:"list"`

	// MD5 hash of the inventory item type contents. The content hash is used to
	// determine whether to update inventory information. The PutInventory API does
	// not update the inventory item type contents if the MD5 hash has not changed
	// since last update.
	ContentHash *string `type:"string"`

	// The schema version for the inventory item.
	//
	// SchemaVersion is a required field
	SchemaVersion *string `type:"string" required:"true"`
	//
	// TypeName is a required field
	TypeName *string `min:"1" type:"string" required:"true"`
}

type Item

type Item struct {
	Name string
	//content depends on inventory type - hence set as interface{} here.
	//e.g: for application - it will contain []ApplicationData,
	//for instanceInformation - it will contain []InstanceInformation.
	Content       interface{}
	ContentHash   string
	SchemaVersion string
	CaptureTime   string
}

Item encapsulates an inventory item

type NetworkData

type NetworkData struct {
	DHCPServer string `json:",omitempty"`
	DNSServer  string `json:",omitempty"`
	Gateway    string `json:",omitempty"`
	IPV4       string
	IPV6       string
	MacAddress string
	Name       string
	SubnetMask string `json:",omitempty"`
}

NetworkData captures all attributes present in ACS:Network inventory type

type Policy

type Policy struct {
	InventoryPolicy map[string]Config `json:"Policy"`
}

type PutInventoryInput

type PutInventoryInput struct {

	// An instance ID where you want to add or update inventory items.
	//
	// InstanceId is a required field
	InstanceId *string `type:"string" required:"true"`

	// The inventory items that you want to add or update on instances.
	//
	// Items is a required field
	Items []*InventoryItem `min:"1" type:"list" required:"true"`
}

type RegistryData

type RegistryData struct {
	KeyPath   string
	Value     string
	ValueName string
	ValueType string
}

type RoleData

type RoleData struct {
	DependsOn                 string
	Description               string
	DisplayName               string
	FeatureType               string
	Installed                 string
	InstalledState            string
	Name                      string
	Parent                    string
	Path                      string
	ServerComponentDescriptor string
	SubFeatures               string
}

type ServiceData

type ServiceData struct {
	DependentServices  string
	DisplayName        string
	Name               string
	ServiceType        string
	ServicesDependedOn string
	StartType          string
	Status             string
}

type WindowsUpdateData

type WindowsUpdateData struct {
	Description   string
	HotFixId      string
	InstalledBy   string
	InstalledTime string
}

Jump to

Keyboard shortcuts

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