-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of github.com:flyteorg/flytekit-java into sdkli…
…teraltype-nesting-v2 Signed-off-by: Rafael Raposo <rafaelraposo@spotify.com>
- Loading branch information
Showing
37 changed files
with
1,341 additions
and
304 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
syntax = "proto3"; | ||
|
||
package flyteidl.admin; | ||
option go_package = "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/admin"; | ||
|
||
import "flyteidl/core/literals.proto"; | ||
import "flyteidl/core/tasks.proto"; | ||
import "flyteidl/core/interface.proto"; | ||
import "flyteidl/core/identifier.proto"; | ||
|
||
// The state of the execution is used to control its visibility in the UI/CLI. | ||
enum State { | ||
RETRYABLE_FAILURE = 0; | ||
PERMANENT_FAILURE = 1; | ||
PENDING = 2; | ||
RUNNING = 3; | ||
SUCCEEDED = 4; | ||
} | ||
|
||
// Represents a subset of runtime task execution metadata that are relevant to external plugins. | ||
message TaskExecutionMetadata { | ||
// ID of the task execution | ||
core.TaskExecutionIdentifier task_execution_id = 1; | ||
// k8s namespace where the task is executed in | ||
string namespace = 2; | ||
// Labels attached to the task execution | ||
map<string, string> labels = 3; | ||
// Annotations attached to the task execution | ||
map<string, string> annotations = 4; | ||
// k8s service account associated with the task execution | ||
string k8s_service_account = 5; | ||
// Environment variables attached to the task execution | ||
map<string, string> environment_variables = 6; | ||
} | ||
|
||
// Represents a request structure to create task. | ||
message CreateTaskRequest { | ||
// The inputs required to start the execution. All required inputs must be | ||
// included in this map. If not required and not provided, defaults apply. | ||
// +optional | ||
core.LiteralMap inputs = 1; | ||
// Template of the task that encapsulates all the metadata of the task. | ||
core.TaskTemplate template = 2; | ||
// Prefix for where task output data will be written. (e.g. s3://my-bucket/randomstring) | ||
string output_prefix = 3; | ||
// subset of runtime task execution metadata. | ||
TaskExecutionMetadata task_execution_metadata = 4; | ||
} | ||
|
||
// Represents a create response structure. | ||
message CreateTaskResponse { | ||
// Metadata is created by the agent. It could be a string (jobId) or a dict (more complex metadata). | ||
bytes resource_meta = 1; | ||
} | ||
|
||
// A message used to fetch a job resource from flyte agent server. | ||
message GetTaskRequest { | ||
// A predefined yet extensible Task type identifier. | ||
string task_type = 1; | ||
// Metadata about the resource to be pass to the agent. | ||
bytes resource_meta = 2; | ||
} | ||
|
||
// Response to get an individual task resource. | ||
message GetTaskResponse { | ||
Resource resource = 1; | ||
} | ||
|
||
message Resource { | ||
// The state of the execution is used to control its visibility in the UI/CLI. | ||
State state = 1; | ||
// The outputs of the execution. It's typically used by sql task. Agent service will create a | ||
// Structured dataset pointing to the query result table. | ||
// +optional | ||
core.LiteralMap outputs = 2; | ||
} | ||
|
||
// A message used to delete a task. | ||
message DeleteTaskRequest { | ||
// A predefined yet extensible Task type identifier. | ||
string task_type = 1; | ||
// Metadata about the resource to be pass to the agent. | ||
bytes resource_meta = 2; | ||
} | ||
|
||
// Response to delete a task. | ||
message DeleteTaskResponse { | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
95 changes: 95 additions & 0 deletions
95
flyteidl-protos/src/main/proto/flyteidl/admin/description_entity.proto
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
syntax = "proto3"; | ||
|
||
package flyteidl.admin; | ||
option go_package = "github.com/flyteorg/flyteidl/gen/pb-go/flyteidl/admin"; | ||
|
||
import "flyteidl/core/identifier.proto"; | ||
import "flyteidl/admin/common.proto"; | ||
|
||
// DescriptionEntity contains detailed description for the task/workflow. | ||
// Documentation could provide insight into the algorithms, business use case, etc. | ||
message DescriptionEntity { | ||
// id represents the unique identifier of the description entity. | ||
core.Identifier id = 1; | ||
// One-liner overview of the entity. | ||
string short_description = 2; | ||
// Full user description with formatting preserved. | ||
Description long_description = 3; | ||
// Optional link to source code used to define this entity. | ||
SourceCode source_code = 4; | ||
// User-specified tags. These are arbitrary and can be used for searching | ||
// filtering and discovering tasks. | ||
repeated string tags = 5; | ||
} | ||
|
||
// The format of the long description | ||
enum DescriptionFormat { | ||
DESCRIPTION_FORMAT_UNKNOWN = 0; | ||
DESCRIPTION_FORMAT_MARKDOWN = 1; | ||
DESCRIPTION_FORMAT_HTML = 2; | ||
// python default documentation - comments is rst | ||
DESCRIPTION_FORMAT_RST = 3; | ||
} | ||
|
||
// Full user description with formatting preserved. This can be rendered | ||
// by clients, such as the console or command line tools with in-tact | ||
// formatting. | ||
message Description { | ||
oneof content { | ||
// long description - no more than 4KB | ||
string value = 1; | ||
// if the description sizes exceed some threshold we can offload the entire | ||
// description proto altogether to an external data store, like S3 rather than store inline in the db | ||
string uri = 2; | ||
} | ||
|
||
// Format of the long description | ||
DescriptionFormat format = 3; | ||
// Optional link to an icon for the entity | ||
string icon_link = 4; | ||
} | ||
|
||
// Link to source code used to define this entity | ||
message SourceCode { | ||
string link = 1; | ||
} | ||
|
||
// Represents a list of DescriptionEntities returned from the admin. | ||
// See :ref:`ref_flyteidl.admin.DescriptionEntity` for more details | ||
message DescriptionEntityList { | ||
// A list of DescriptionEntities returned based on the request. | ||
repeated DescriptionEntity descriptionEntities = 1; | ||
|
||
// In the case of multiple pages of results, the server-provided token can be used to fetch the next page | ||
// in a query. If there are no more results, this value will be empty. | ||
string token = 2; | ||
} | ||
|
||
// Represents a request structure to retrieve a list of DescriptionEntities. | ||
// See :ref:`ref_flyteidl.admin.DescriptionEntity` for more details | ||
message DescriptionEntityListRequest { | ||
// Identifies the specific type of resource that this identifier corresponds to. | ||
flyteidl.core.ResourceType resource_type = 1; | ||
|
||
// The identifier for the description entity. | ||
// +required | ||
NamedEntityIdentifier id = 2; | ||
|
||
// Indicates the number of resources to be returned. | ||
// +required | ||
uint32 limit = 3; | ||
|
||
// In the case of multiple pages of results, the server-provided token can be used to fetch the next page | ||
// in a query. | ||
// +optional | ||
string token = 4; | ||
|
||
// Indicates a list of filters passed as string. | ||
// More info on constructing filters : <Link> | ||
// +optional | ||
string filters = 5; | ||
|
||
// Sort ordering for returned list. | ||
// +optional | ||
Sort sort_by = 6; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.