converter

package
v2.0.48 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2026 License: Apache-2.0 Imports: 17 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func JSONValuesToLiterals

func JSONValuesToLiterals(ctx context.Context, variableMap *core.VariableMap, values *structpb.Struct) ([]*task.NamedLiteral, error)

JSONValuesToLiterals converts a raw JSON object (values) into NamedLiterals using the provided type definitions in variableMap. This is a thin wrapper around jsonValueToLiteralWithFieldName that understands Flyte's LiteralType.

  • variableMap: describes the expected inputs (types, names)
  • values: a Struct whose fields are the raw JSON values, e.g.: { "batch_index": 1, "batch_info": { ... }, "output_context": {}, "queue_offset": 1 }

func LaunchFormJsonToLiterals

func LaunchFormJsonToLiterals(ctx context.Context, jsonSchema *structpb.Struct) ([]*task.NamedLiteral, error)

LaunchFormJsonToLiterals converts an RSJF JSON schema to a list of NamedLiterals.

func LiteralsToLaunchFormJson

func LiteralsToLaunchFormJson(ctx context.Context, literals []*task.NamedLiteral, variableMap *core.VariableMap) (*structpb.Struct, error)

LiteralsToLaunchFormJson converts a list of NamedLiterals accompanied by a VariableMap to RSJF-compliant JSON schema format.

func TaskSpecToLaunchFormJson

func TaskSpecToLaunchFormJson(ctx context.Context, taskSpec *task.TaskSpec) (*structpb.Struct, error)

TaskSpecToLaunchFormJson converts a TaskSpec to an RSJF-compliant JSON schema.

Types

This section is empty.

Jump to

Keyboard shortcuts

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