oam

package
v0.5.4 Latest Latest
Warning

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

Go to latest
Published: May 5, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package oam contains the definitions for OAM objects as well as the parsers and register functions associated with it

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseApplicationComponent

func ParseApplicationComponent(jsn string) (acomp v1alpha1.Component, err error)

ParseApplicationComponent converts json application component to go struct

func ParseApplicationConfiguration

func ParseApplicationConfiguration(jsn string) (acomp v1alpha1.Configuration, err error)

ParseApplicationConfiguration converts json application configuration to go struct

func RegisterTraits

func RegisterTraits(runtime, host string) error

RegisterTraits will register all of the trait definitions present in the path oam/traits

Registeration process will send POST request to $runtime/api/experimental/oam/trait

func RegisterWorkloads

func RegisterWorkloads(runtime, host string) error

RegisterWorkloads will register all of the workload definitions present in the path oam/workloads

Registeration process will send POST request to $runtime/api/experimental/oam/workload

Types

type GenericStructure

type GenericStructure struct {
	OAMDefinition interface{} `json:"oam_definition,omitempty"`
	OAMRefSchema  string      `json:"oam_ref_schema,omitempty"`
	Host          string      `json:"host,omitempty"`
}

GenericStructure struct defines the body of the POST request that is sent to the OAM registry (Meshery)

The body contains the 1. OAM definition, which is in accordance with the OAM spec 2. OAMRefSchema, which is json schema draft-4, draft-7 or draft-8 for the corresponding OAM object 3. Host is this service's grpc address in the form of `hostname:port`

Directories

Path Synopsis
core
v1alpha1
Package v1alpha1 contains the definitions for OAM core/v1alpha1 objects The definitions inlcude: 1.
Package v1alpha1 contains the definitions for OAM core/v1alpha1 objects The definitions inlcude: 1.

Jump to

Keyboard shortcuts

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