Skip to content

Commit b7d2ab2

Browse files
authored
Initial skeleton code for Agent service (#651)
## Summary Skeleton implementation for Agent service with job polling and status reporting happening at regular intervals which can be configured. A lot of place holder code which is going to change a lot in coming PR's so didn't add tests for now, will add them in coming PR's ## Cheour clientslist - [ ] Added Unit Tests - [ ] Covered by existing CI - [ ] Integration tested - [ ] Documentation update <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Introduced configuration management for agent components, including polling intervals and service endpoints. - Added abstractions and in-memory implementations for job execution and key-value storage services. - Implemented periodic job polling and status reporting handlers for orchestration agents. - Added Vert.x verticles to manage job polling and status reporting workflows. - **Improvements** - Enhanced job struct to use a detailed job info field. - Expanded job status types with an explicit "unknown" state and updated status codes. - **Dependency Updates** - Included additional Vert.x dependencies for URI template support. - Paour clientsaged resource files into the orchestration binary. - **Bug Fixes** - Updated job handling logic and tests to reflect changes in job ID access patterns. - **Tests** - Adjusted tests to accommodate the new job info structure. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
1 parent a74dca9 commit b7d2ab2

File tree

2 files changed

+9
-6
lines changed

2 files changed

+9
-6
lines changed

api/thrift/agent.thrift

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ union JobBase {
7575
}
7676

7777
struct Job {
78-
1: optional string jobId
78+
1: optional JobInfo jobInfo
7979
2: optional JobBase jobUnion
8080
3: optional i32 statusReportInterval
8181
4: optional i32 maxRetries
@@ -93,11 +93,12 @@ struct JobListResponse {
9393
}
9494

9595
enum JobStatusType {
96-
PENDING = 0,
97-
RUNNING = 1,
98-
SUCCEEDED = 2,
99-
FAILED = 3,
100-
STOPPED = 4
96+
UNKNOWN = 0,
97+
PENDING = 1,
98+
RUNNING = 2,
99+
SUCCEEDED = 3,
100+
FAILED = 4,
101+
STOPPED = 5
101102
}
102103

103104
struct ResourceUsage {

tools/build_rules/prelude_bazel

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@ _VERTX_DEPS = [
8989
maven_artifact("io.vertx:vertx-core"),
9090
maven_artifact("io.vertx:vertx-web"),
9191
maven_artifact("io.vertx:vertx-web-client"),
92+
maven_artifact("io.vertx:vertx-uri-template"),
9293
maven_artifact("io.vertx:vertx-config"),
9394
maven_artifact("io.vertx:vertx-micrometer-metrics"),
9495
]
@@ -98,6 +99,7 @@ _VERTX_TEST_DEPS = [
9899
maven_artifact("io.vertx:vertx-core"),
99100
maven_artifact("io.vertx:vertx-web"),
100101
maven_artifact("io.vertx:vertx-web-client"),
102+
maven_artifact("io.vertx:vertx-uri-template"),
101103
# Testing
102104
maven_artifact("io.vertx:vertx-junit5"),
103105
maven_artifact("io.vertx:vertx-unit"),

0 commit comments

Comments
 (0)