diff --git a/.github/workflows/fasttask.yml b/.github/workflows/fasttask.yml new file mode 100644 index 00000000000..c8921f771a1 --- /dev/null +++ b/.github/workflows/fasttask.yml @@ -0,0 +1,23 @@ +name: fasttask tests + + +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + +on: + pull_request: + push: + branches: + - master + + +jobs: + lint: + name: Lint + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Rust linting + run: cargo fmt --all -- --check + working-directory: fasttask/worker diff --git a/fasttask/worker/bridge/src/pb/fasttask.rs b/fasttask/worker/bridge/src/pb/fasttask.rs index db469dd2f4e..9b2816b91be 100644 --- a/fasttask/worker/bridge/src/pb/fasttask.rs +++ b/fasttask/worker/bridge/src/pb/fasttask.rs @@ -2,53 +2,53 @@ #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct TaskStatus { - #[prost(string, tag="1")] + #[prost(string, tag = "1")] pub task_id: ::prost::alloc::string::String, - #[prost(string, tag="2")] + #[prost(string, tag = "2")] pub namespace: ::prost::alloc::string::String, - #[prost(string, tag="3")] + #[prost(string, tag = "3")] pub workflow_id: ::prost::alloc::string::String, - #[prost(int32, tag="4")] + #[prost(int32, tag = "4")] pub phase: i32, - #[prost(string, tag="5")] + #[prost(string, tag = "5")] pub reason: ::prost::alloc::string::String, } #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct Capacity { - #[prost(int32, tag="1")] + #[prost(int32, tag = "1")] pub execution_count: i32, - #[prost(int32, tag="2")] + #[prost(int32, tag = "2")] pub execution_limit: i32, - #[prost(int32, tag="3")] + #[prost(int32, tag = "3")] pub backlog_count: i32, - #[prost(int32, tag="4")] + #[prost(int32, tag = "4")] pub backlog_limit: i32, } #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct HeartbeatRequest { - #[prost(string, tag="1")] + #[prost(string, tag = "1")] pub worker_id: ::prost::alloc::string::String, - #[prost(string, tag="2")] + #[prost(string, tag = "2")] pub queue_id: ::prost::alloc::string::String, - #[prost(message, optional, tag="3")] + #[prost(message, optional, tag = "3")] pub capacity: ::core::option::Option, - #[prost(message, repeated, tag="4")] + #[prost(message, repeated, tag = "4")] pub task_statuses: ::prost::alloc::vec::Vec, } #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct HeartbeatResponse { - #[prost(string, tag="1")] + #[prost(string, tag = "1")] pub task_id: ::prost::alloc::string::String, - #[prost(string, tag="2")] + #[prost(string, tag = "2")] pub namespace: ::prost::alloc::string::String, - #[prost(string, tag="3")] + #[prost(string, tag = "3")] pub workflow_id: ::prost::alloc::string::String, - #[prost(string, repeated, tag="4")] + #[prost(string, repeated, tag = "4")] pub cmd: ::prost::alloc::vec::Vec<::prost::alloc::string::String>, - #[prost(enumeration="heartbeat_response::Operation", tag="5")] + #[prost(enumeration = "heartbeat_response::Operation", tag = "5")] pub operation: i32, } /// Nested message and enum types in `HeartbeatResponse`. @@ -86,33 +86,34 @@ pub mod heartbeat_response { #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct FastTaskEnvironment { - #[prost(string, tag="1")] + #[prost(string, tag = "1")] pub queue_id: ::prost::alloc::string::String, } #[allow(clippy::derive_partial_eq_without_eq)] #[derive(Clone, PartialEq, ::prost::Message)] pub struct FastTaskEnvironmentSpec { - #[prost(int32, tag="1")] + #[prost(int32, tag = "1")] pub backlog_length: i32, - #[prost(int32, tag="2")] + #[prost(int32, tag = "2")] pub parallelism: i32, - #[prost(bytes="vec", tag="3")] + #[prost(bytes = "vec", tag = "3")] pub pod_template_spec: ::prost::alloc::vec::Vec, - #[prost(string, tag="4")] + #[prost(string, tag = "4")] pub primary_container_name: ::prost::alloc::string::String, - #[prost(int32, tag="5")] + #[prost(int32, tag = "5")] pub replica_count: i32, - #[prost(oneof="fast_task_environment_spec::TerminationCriteria", tags="6")] - pub termination_criteria: ::core::option::Option, + #[prost(oneof = "fast_task_environment_spec::TerminationCriteria", tags = "6")] + pub termination_criteria: + ::core::option::Option, } /// Nested message and enum types in `FastTaskEnvironmentSpec`. pub mod fast_task_environment_spec { #[allow(clippy::derive_partial_eq_without_eq)] -#[derive(Clone, PartialEq, ::prost::Oneof)] + #[derive(Clone, PartialEq, ::prost::Oneof)] pub enum TerminationCriteria { - #[prost(int32, tag="6")] + #[prost(int32, tag = "6")] TtlSeconds(i32), } } include!("fasttask.tonic.rs"); -// @@protoc_insertion_point(module) \ No newline at end of file +// @@protoc_insertion_point(module)