Documentation
¶
Index ¶
- Constants
- func ErrAbsentFilter(err error) error
- func ErrCreatingDirectory(err error) error
- func ErrGetAPIGroup(err error) error
- func ErrGetAPIVersion(err error) error
- func ErrGetCrdNames(err error) error
- func ErrGetResourceIdentifier(err error) error
- func ErrGetSchemas(err error) error
- func ErrPopulatingYaml(err error) error
- func FormatToReadableString(input string) string
- func ResolveReferences(manifest []byte, definitions cue.Value) ([]byte, error)
- type Component
- func GenerateComponents(ctx context.Context, manifest string, resource int, cfg Config) (*Component, error)
- func GetFromHelm(ctx context.Context, url string, resource int, cfg Config) (*Component, error)
- func GetFromManifest(ctx context.Context, url string, resource int, cfg Config) (*Component, error)
- type Config
- type CueCrdFilter
- type CueFilter
- type ExtractorPaths
Constants ¶
View Source
const ( // service mesh resource SERVICE_MESH = iota // native Kubernetes resource K8s // native Meshery resource MESHERY )
Type of resource
View Source
const ( ErrGetCrdNamesCode = "1001" ErrGetSchemasCode = "1002" ErrGetAPIVersionCode = "1003" ErrGetAPIGroupCode = "1004" ErrPopulatingYamlCode = "1005" ErrAbsentFilterCode = "1006" ErrCreatingDirectoryCode = "1007" ErrGetResourceIdentifierCode = "11075" )
Variables ¶
This section is empty.
Functions ¶
func ErrAbsentFilter ¶ added in v0.2.30
func ErrCreatingDirectory ¶ added in v0.5.10
func ErrGetAPIGroup ¶
func ErrGetAPIVersion ¶
func ErrGetCrdNames ¶
func ErrGetResourceIdentifier ¶ added in v0.5.19
func ErrGetSchemas ¶
func ErrPopulatingYaml ¶
func FormatToReadableString ¶ added in v0.5.1
While going from Capital letter to small, insert a whitespace before the capital letter. While going from small letter to capital, insert a whitespace after the small letter
Types ¶
type Config ¶
type Config struct { Name string // Name of the service mesh,or k8 or meshery Type string //Type of the workload like- Istio, TraefikMesh, Kuma, OSM, Linkerd,AppMesh,NginxMesh MeshVersion string // For service meshes K8sVersion string //For K8ss ModifyDefSchema func(*string, *string) //takes in definition and schema, does some manipulation on them and returns the new def and schema CrdFilter CueCrdFilter ExtractCrds func(manifest string) []string //takes in the manifest and returns a list of all the crds }
all the data that is needed to get a certain value should be present in the config created by the adapter.
type CueCrdFilter ¶ added in v0.5.19
type CueCrdFilter struct { NameExtractor CueFilter GroupExtractor CueFilter VersionExtractor CueFilter SpecExtractor CueFilter IsJson bool IdentifierExtractor CueFilter // identifiers are the values that uniquely identify a CRD (in most of the cases, it is the 'Name' field) }
basically getter functions applicable for a single CRD can be interpreted as the things that are needed for generating a Component
func NewCueCrdFilter ¶ added in v0.5.19
func NewCueCrdFilter(ep ExtractorPaths, isJson bool) CueCrdFilter
Click to show internal directories.
Click to hide internal directories.