Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion apis/workflows/v1/core.proto
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,12 @@ message TaskSubmissionGroup {
// The input parameters for each task.
// We explicitly don't group the fields into a submessage and then have a single repeated field for that submessage,
// to enable packed encoding of the repeated fields.
repeated bytes inputs = 2 [(buf.validate.field).repeated.items.bytes.max_len = 2048];
repeated bytes inputs = 2 [(buf.validate.field).repeated = {
min_items: 1 // we don't allow empty submission groups
items: {
bytes: {max_len: 2048}
}
}];
// Index of the task identifier in the identifier_lookup field of the containing TaskSubmissions message
// for each task.
repeated uint64 identifier_pointers = 3;
Expand Down
6 changes: 6 additions & 0 deletions apis/workflows/v1/job.proto
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@ option features.field_presence = IMPLICIT;

// SubmitJobRequest submits and schedules a job for execution. The job can have multiple root tasks.
message SubmitJobRequest {
option (buf.validate.message).cel = {
id: "submit_job_request.tasks_required"
message: "At least one task must be submitted."
expression: "(this.tasks != null && this.tasks.task_groups.size() > 0) || this.legacy_tasks.size() > 0"
};

// The root tasks for the job.
TaskSubmissions tasks = 5;
// The name of the job.
Expand Down