Documentation
¶
Overview ¶
Package connection provides primitives to interact with the openapi HTTP API.
Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.7.1 DO NOT EDIT.
The file implements the meshkit registry Entity interface on the ConnectionDefinition struct so that connection definitions can be registered and queried like components and relationships. This is not autogenerated.
Code generated by build/generate-golang.js; DO NOT EDIT.
Index ¶
- Constants
- type Connection
- type ConnectionDefinition
- func (c *ConnectionDefinition) Create(db *database.Handler, hostID uuid.UUID) (uuid.UUID, error)
- func (c *ConnectionDefinition) GenerateID() (uuid.UUID, error)
- func (c *ConnectionDefinition) GetEntityDetail() string
- func (c ConnectionDefinition) GetID() uuid.UUID
- func (c ConnectionDefinition) TableName() string
- func (c ConnectionDefinition) Type() entity.EntityType
- func (c *ConnectionDefinition) UpdateStatus(db *database.Handler, status entity.EntityStatus) error
- type ConnectionDefinitionId
- type ConnectionDefinitionPage
- type ConnectionId
- type ConnectionKind
- type ConnectionPage
- type ConnectionPayload
- type ConnectionStateTransition
- type ConnectionStatus
- type ConnectionStatusInfo
- type ConnectionStatusValue
- type ConnectionsStatusPage
- type EnvironmentId
- type MesheryCompatibility
- type MesheryInstance
- type MesheryInstancePage
- type MesheryServerId
- type Order
- type OrgIdQuery
- type Page
- type PageSize
- type Search
Constants ¶
const ( // Deprecated: Use ConnectionStatusValueConnected instead. Connected = ConnectionStatusValueConnected // Deprecated: Use ConnectionStatusValueDeleted instead. Deleted = ConnectionStatusValueDeleted // Deprecated: Use ConnectionStatusValueDisconnected instead. Disconnected = ConnectionStatusValueDisconnected // Deprecated: Use ConnectionStatusValueDiscovered instead. Discovered = ConnectionStatusValueDiscovered // Deprecated: Use ConnectionStatusValueIgnored instead. Ignored = ConnectionStatusValueIgnored // Deprecated: Use ConnectionStatusValueMaintenance instead. Maintenance = ConnectionStatusValueMaintenance // Deprecated: Use ConnectionStatusValueNotFound instead. NotFound = ConnectionStatusValueNotFound // Deprecated: Use ConnectionStatusValueRegistered instead. Registered = ConnectionStatusValueRegistered )
Deprecated aliases for ConnectionStatusValue constants.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Connection ¶
type Connection struct {
// ID A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
ID core.Uuid `db:"id" json:"id" yaml:"id"`
// Name Connection Name
Name string `db:"name" json:"name" yaml:"name"`
// Description Human-readable description of the connection and its purpose.
Description *string `db:"description" json:"description" yaml:"description"`
// Url URL of the remote resource this connection points to (e.g. the Helm repository URL, the Kubernetes API server endpoint, the Grafana instance URL).
Url *string `db:"url" json:"url" yaml:"url"`
// CredentialID A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
CredentialID *core.Uuid `db:"credential_id" json:"credentialId" yaml:"credentialId"`
// ConnectionType Connection Type (platform, telemetry, collaboration)
ConnectionType string `db:"type" json:"type" yaml:"type"`
// Model Meshery Models serve as a portable unit of packaging to define managed entities, their relationships, and capabilities.
Model *modelv1beta1.ModelDefinition `gorm:"foreignKey:ModelID;references:ID" json:"model" yaml:"model"`
// SubType Connection Subtype (cloud, identity, metrics, chat, git, orchestration)
SubType string `db:"sub_type" json:"subType" yaml:"subType"`
// Kind Connection Kind (meshery, kubernetes, prometheus, grafana, gke, aws, azure, slack, github)
Kind string `db:"kind" json:"kind" yaml:"kind"`
// ModelReference Reference to the specific registered model to which the component belongs and from which model version, category, and other properties may be referenced. Learn more at https://docs.meshery.io/concepts/models
ModelReference *modelv1beta1.ModelReference `gorm:"-" json:"modelReference,omitempty" yaml:"modelReference,omitempty"`
// ConnectionSchema Schema for the connection
ConnectionSchema core.Map `db:"connection_schema" json:"connectionSchema,omitempty" yaml:"connectionSchema,omitempty"`
// CredentialSchema Schema for the credential Associated with the connection
CredentialSchema core.Map `db:"credential_schema" json:"credentialSchema,omitempty" yaml:"credentialSchema,omitempty"`
// Metadata Additional connection metadata
Metadata core.Map `db:"metadata" json:"metadata,omitempty" yaml:"metadata,omitempty"`
// Status Connection Status
Status ConnectionStatus `db:"status" json:"status" yaml:"status"`
// Owner A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
Owner *core.Uuid `db:"owner" json:"owner" yaml:"owner"`
CreatedAt core.Time `db:"created_at" json:"createdAt" yaml:"createdAt"`
UpdatedAt core.Time `db:"updated_at" json:"updatedAt" yaml:"updatedAt"`
// DeletedAt SQL null Timestamp to handle null values of time.
DeletedAt core.NullTime `db:"deleted_at" json:"deletedAt" yaml:"deletedAt"`
// Environments Associated environments for this connection
Environments []*environmentv1beta3.Environment `db:"-" gorm:"-" json:"environments,omitempty" yaml:"environments,omitempty"`
// SchemaVersion API version of the object, optionally prefixed with an API group (e.g. "group.example.io/v1beta1" or bare "v1beta1").
SchemaVersion core.VersionString `db:"-" gorm:"-" json:"schemaVersion" yaml:"schemaVersion"`
// Styles Visualization styles for a component
Styles *core.ComponentStyles `gorm:"type:bytes;serializer:json" json:"styles" yaml:"styles"`
// TransitionMap Map describing the connection state machine. Each key is a current connection status and its value is the list of states the connection may transition to from that status, along with a description of each transition.
TransitionMap map[string][]ConnectionStateTransition `gorm:"type:bytes;serializer:json" json:"transitionMap,omitempty" yaml:"transitionMap,omitempty"`
// ModelID A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
ModelID *core.Uuid `db:"model_id" gorm:"column:model_id" json:"-" yaml:"-"`
}
Connection Meshery Connections are managed and unmanaged resources that either through discovery or manual entry are tracked by Meshery. Learn more at https://docs.meshery.io/concepts/logical/connections
func (*Connection) EventCategory ¶
func (*Connection) EventCategory() string
type ConnectionDefinition ¶ added in v1.3.9
type ConnectionDefinition = Connection
ConnectionDefinition A connection definition is an uninitialized connection, authored per-model (in a model's `connections/` folder) and registered into the registry alongside components and relationships. It conforms to the connection schema; the dynamic, kind-specific shape is carried in `metadata`. The `model` association scopes the definition to its owning model.
func (*ConnectionDefinition) GenerateID ¶ added in v1.3.9
func (c *ConnectionDefinition) GenerateID() (uuid.UUID, error)
func (*ConnectionDefinition) GetEntityDetail ¶ added in v1.3.9
func (c *ConnectionDefinition) GetEntityDetail() string
func (ConnectionDefinition) GetID ¶ added in v1.3.9
func (c ConnectionDefinition) GetID() uuid.UUID
func (ConnectionDefinition) TableName ¶ added in v1.3.9
func (c ConnectionDefinition) TableName() string
func (ConnectionDefinition) Type ¶ added in v1.3.9
func (c ConnectionDefinition) Type() entity.EntityType
func (*ConnectionDefinition) UpdateStatus ¶ added in v1.3.9
func (c *ConnectionDefinition) UpdateStatus(db *database.Handler, status entity.EntityStatus) error
type ConnectionDefinitionId ¶ added in v1.3.9
type ConnectionDefinitionId = openapi_types.UUID
ConnectionDefinitionId defines model for connectionDefinitionId.
type ConnectionDefinitionPage ¶ added in v1.3.9
type ConnectionDefinitionPage struct {
// ConnectionDefinitions List of connection definitions on this page
ConnectionDefinitions []*ConnectionDefinition `json:"connectionDefinitions" yaml:"connectionDefinitions"`
// TotalCount Total number of connection definitions on all pages
TotalCount int `json:"totalCount" yaml:"totalCount"`
// Page Current page number
Page int `json:"page" yaml:"page"`
// PageSize Number of elements per page
PageSize int `json:"pageSize" yaml:"pageSize"`
}
ConnectionDefinitionPage Represents a page of connection definitions with meta information about the total count
type ConnectionId ¶
type ConnectionId = openapi_types.UUID
ConnectionId defines model for connectionId.
type ConnectionPage ¶
type ConnectionPage struct {
// Connections List of connections on this page
Connections []*Connection `json:"connections" yaml:"connections"`
// TotalCount Total number of connections on all pages
TotalCount int `json:"totalCount" yaml:"totalCount"`
// Page Current page number
Page int `json:"page" yaml:"page"`
// PageSize Number of elements per page
PageSize int `json:"pageSize" yaml:"pageSize"`
// StatusSummary Aggregate count of connections grouped by status
StatusSummary *map[ConnectionStatusValue]int `json:"statusSummary,omitempty" yaml:"statusSummary,omitempty"`
}
ConnectionPage Represents a page of connections with meta information about connections count
type ConnectionPayload ¶
type ConnectionPayload struct {
// CredentialID Associated credential ID
CredentialID *openapi_types.UUID `json:"credentialId,omitempty" yaml:"credentialId,omitempty"`
// CredentialSecret Credential secret data
CredentialSecret core.Map `json:"credentialSecret" yaml:"credentialSecret"`
// ConnectionID Connection ID
ConnectionID *openapi_types.UUID `json:"id,omitempty" yaml:"id,omitempty"`
// Kind Connection kind
Kind string `json:"kind" yaml:"kind"`
// Metadata Connection metadata
Metadata core.Map `json:"metadata" yaml:"metadata"`
// Name Connection name
Name string `json:"name" yaml:"name"`
// Status Connection status
Status string `json:"status" yaml:"status"`
// Styles Visualization styles for a component
Styles *core.ComponentStyles `json:"styles,omitempty" yaml:"styles,omitempty"`
// SubType Connection sub-type
SubType string `json:"subType" yaml:"subType"`
// Type Connection type
Type string `json:"type" yaml:"type"`
}
ConnectionPayload Payload for creating or updating a connection
type ConnectionStateTransition ¶ added in v1.3.9
type ConnectionStateTransition struct {
// NextState Connection Status Value
NextState ConnectionStatusValue `json:"nextState" yaml:"nextState"`
// Description Human-readable explanation of when or why this transition occurs.
Description *string `json:"description,omitempty" yaml:"description,omitempty"`
}
ConnectionStateTransition A single permissible state transition for a connection, describing the next reachable state and the meaning of that transition.
type ConnectionStatus ¶
type ConnectionStatus string
ConnectionStatus Connection Status
const ( ConnectionStatusConnected ConnectionStatus = "connected" ConnectionStatusDeleted ConnectionStatus = "deleted" ConnectionStatusDisconnected ConnectionStatus = "disconnected" ConnectionStatusDiscovered ConnectionStatus = "discovered" ConnectionStatusIgnored ConnectionStatus = "ignored" ConnectionStatusMaintenance ConnectionStatus = "maintenance" ConnectionStatusNotFound ConnectionStatus = "not found" ConnectionStatusRegistered ConnectionStatus = "registered" )
Defines values for ConnectionStatus.
func (ConnectionStatus) Valid ¶ added in v1.4.0
func (e ConnectionStatus) Valid() bool
Valid indicates whether the value is a known member of the ConnectionStatus enum.
type ConnectionStatusInfo ¶
type ConnectionStatusInfo struct {
// Count Number of connections with this status
Count int `db:"count" json:"count" yaml:"count"`
// Status Status value
Status string `db:"status" json:"status" yaml:"status"`
}
ConnectionStatusInfo Status count information for connections
type ConnectionStatusValue ¶
type ConnectionStatusValue string
ConnectionStatusValue Connection Status Value
const ( ConnectionStatusValueConnected ConnectionStatusValue = "connected" ConnectionStatusValueDeleted ConnectionStatusValue = "deleted" ConnectionStatusValueDisconnected ConnectionStatusValue = "disconnected" ConnectionStatusValueDiscovered ConnectionStatusValue = "discovered" ConnectionStatusValueIgnored ConnectionStatusValue = "ignored" ConnectionStatusValueMaintenance ConnectionStatusValue = "maintenance" ConnectionStatusValueNotFound ConnectionStatusValue = "not found" ConnectionStatusValueRegistered ConnectionStatusValue = "registered" )
Defines values for ConnectionStatusValue.
func (ConnectionStatusValue) Valid ¶ added in v1.4.0
func (e ConnectionStatusValue) Valid() bool
Valid indicates whether the value is a known member of the ConnectionStatusValue enum.
type ConnectionsStatusPage ¶
type ConnectionsStatusPage struct {
// ConnectionsStatus List of status counts
ConnectionsStatus []ConnectionStatusInfo `json:"connectionsStatus" yaml:"connectionsStatus"`
// Page Current page number
Page int `json:"page" yaml:"page"`
// PageSize Number of items per page
PageSize int `json:"pageSize" yaml:"pageSize"`
// TotalCount Total number of status entries
TotalCount int `json:"totalCount" yaml:"totalCount"`
}
ConnectionsStatusPage Paginated list of connection status counts
type EnvironmentId ¶
type EnvironmentId = openapi_types.UUID
EnvironmentId defines model for environmentId.
type MesheryCompatibility ¶
type MesheryCompatibility struct {
// CheckCompatibility Whether to check compatibility
CheckCompatibility *bool `json:"checkCompatibility,omitempty" yaml:"checkCompatibility,omitempty"`
// MesheryVersion Meshery version string
MesheryVersion *string `json:"mesheryVersion,omitempty" yaml:"mesheryVersion,omitempty"`
}
MesheryCompatibility Meshery version compatibility check
type MesheryInstance ¶
type MesheryInstance struct {
// CreatedAt Creation timestamp
CreatedAt *time.Time `db:"created_at" json:"createdAt,omitempty" yaml:"createdAt,omitempty"`
// DeletedAt Deletion timestamp
DeletedAt *time.Time `db:"deleted_at" json:"deletedAt,omitempty" yaml:"deletedAt,omitempty"`
// Id Instance ID
ID *openapi_types.UUID `db:"id" json:"id,omitempty" yaml:"id,omitempty"`
// Name Instance name
Name *string `db:"name" json:"name,omitempty" yaml:"name,omitempty"`
// ServerBuildSHA Server build SHA
ServerBuildSHA *string `db:"server_build_sha" json:"serverBuildSha,omitempty" yaml:"serverBuildSha,omitempty"`
// ServerID Server ID
ServerID *openapi_types.UUID `db:"server_id" json:"serverId,omitempty" yaml:"serverId,omitempty"`
// ServerLocation Server location URL
ServerLocation *string `db:"server_location" json:"serverLocation,omitempty" yaml:"serverLocation,omitempty"`
// ServerVersion Meshery server version
ServerVersion *string `db:"server_version" json:"serverVersion,omitempty" yaml:"serverVersion,omitempty"`
// UpdatedAt Last update timestamp
UpdatedAt *time.Time `db:"updated_at" json:"updatedAt,omitempty" yaml:"updatedAt,omitempty"`
}
MesheryInstance Meshery server instance information
type MesheryInstancePage ¶
type MesheryInstancePage struct {
// MesheryInstances List of Meshery instances
MesheryInstances []MesheryInstance `json:"mesheryInstances" yaml:"mesheryInstances"`
// Page Current page number
Page int `json:"page" yaml:"page"`
// PageSize Number of items per page
PageSize int `json:"pageSize" yaml:"pageSize"`
// TotalCount Total number of instances
TotalCount int `json:"totalCount" yaml:"totalCount"`
}
MesheryInstancePage Paginated list of Meshery instances
type MesheryServerId ¶
type MesheryServerId = openapi_types.UUID
MesheryServerId defines model for mesheryServerId.