Skip to content

Commit 46cd519

Browse files
committed
work on comments
1 parent bc1cbc9 commit 46cd519

4 files changed

Lines changed: 24 additions & 24 deletions

File tree

openapi/openapiv2.json

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2225,7 +2225,7 @@
22252225
},
22262226
{
22272227
"name": "query",
2228-
"description": "`query` in ListWorkers is used to filter workers based on worker status info.\nThe following worker status attributes are expected are supported as part of the query:\n* WorkerId\n* WorkerIdentity\n* HostId\n* TaskQueue\n* DeploymentName\n* BuildId\n* SdkName\n* SdkVersion\n* Uptime\n* LastHeartbeatTime\n* Status\nCurrently metrics are not supported as a part of ListWorkers query.",
2228+
"description": "`query` in ListWorkers is used to filter workers based on worker status info.\nThe following worker status attributes are expected are supported as part of the query:\n* WorkerId\n* WorkerIdentity\n* HostId\n* TaskQueue\n* DeploymentName\n* BuildId\n* SdkName\n* SdkVersion\n* StartTime\n* LastHeartbeatTime\n* Status\nCurrently metrics are not supported as a part of ListWorkers query.",
22292229
"in": "query",
22302230
"required": false,
22312231
"type": "string"
@@ -5866,7 +5866,7 @@
58665866
},
58675867
{
58685868
"name": "query",
5869-
"description": "`query` in ListWorkers is used to filter workers based on worker status info.\nThe following worker status attributes are expected are supported as part of the query:\n* WorkerId\n* WorkerIdentity\n* HostId\n* TaskQueue\n* DeploymentName\n* BuildId\n* SdkName\n* SdkVersion\n* Uptime\n* LastHeartbeatTime\n* Status\nCurrently metrics are not supported as a part of ListWorkers query.",
5869+
"description": "`query` in ListWorkers is used to filter workers based on worker status info.\nThe following worker status attributes are expected are supported as part of the query:\n* WorkerId\n* WorkerIdentity\n* HostId\n* TaskQueue\n* DeploymentName\n* BuildId\n* SdkName\n* SdkVersion\n* StartTime\n* LastHeartbeatTime\n* Status\nCurrently metrics are not supported as a part of ListWorkers query.",
58705870
"in": "query",
58715871
"required": false,
58725872
"type": "string"
@@ -15290,7 +15290,7 @@
1529015290
"v1WorkerInfo": {
1529115291
"type": "object",
1529215292
"properties": {
15293-
"workerId": {
15293+
"workerInstanceKey": {
1529415294
"type": "string",
1529515295
"description": "Worker identifier, should be unique for the namespace.\nIt is different from worker identity, which is usually a combination of host_name and process_id."
1529615296
},
@@ -15315,9 +15315,10 @@
1531515315
"$ref": "#/definitions/v1WorkerStatus",
1531615316
"description": "Worker status. Possible values - \"running\", \"shutting_down\", \"shutdown\"."
1531715317
},
15318-
"uptime": {
15318+
"startTime": {
1531915319
"type": "string",
15320-
"title": "Uptime of the worker, since it started.\nThis is the time since the worker started, not the time since the last heartbeat.\nIt can be used to determine worker start time. (current time - uptime)"
15320+
"format": "date-time",
15321+
"title": "Worker start time.\nIt can be used to determine worker uptime. (current time - start time)"
1532115322
},
1532215323
"lastHeartbeatTime": {
1532315324
"type": "string",
@@ -15407,7 +15408,7 @@
1540715408
"processedTasks": {
1540815409
"type": "integer",
1540915410
"format": "int32",
15410-
"description": "Total number of tasks processed by the worker so far."
15411+
"description": "Total number of tasks processed (completed both successfully and unsuccesfully)\nby the worker since the worker started. This is a cumulative counter."
1541115412
},
1541215413
"failedTasks": {
1541315414
"type": "integer",

openapi/openapiv3.yaml

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2017,7 +2017,7 @@ paths:
20172017
* BuildId
20182018
* SdkName
20192019
* SdkVersion
2020-
* Uptime
2020+
* StartTime
20212021
* LastHeartbeatTime
20222022
* Status
20232023
Currently metrics are not supported as a part of ListWorkers query.
@@ -5282,7 +5282,7 @@ paths:
52825282
* BuildId
52835283
* SdkName
52845284
* SdkVersion
5285-
* Uptime
5285+
* StartTime
52865286
* LastHeartbeatTime
52875287
* Status
52885288
Currently metrics are not supported as a part of ListWorkers query.
@@ -12682,7 +12682,7 @@ components:
1268212682
WorkerInfo:
1268312683
type: object
1268412684
properties:
12685-
workerId:
12685+
workerInstanceKey:
1268612686
type: string
1268712687
description: |-
1268812688
Worker identifier, should be unique for the namespace.
@@ -12709,13 +12709,12 @@ components:
1270912709
type: string
1271012710
description: Worker status. Possible values - "running", "shutting_down", "shutdown".
1271112711
format: enum
12712-
uptime:
12713-
pattern: ^-?(?:0|[1-9][0-9]{0,11})(?:\.[0-9]{1,9})?s$
12712+
startTime:
1271412713
type: string
1271512714
description: |-
12716-
Uptime of the worker, since it started.
12717-
This is the time since the worker started, not the time since the last heartbeat.
12718-
It can be used to determine worker start time. (current time - uptime)
12715+
Worker start time.
12716+
It can be used to determine worker uptime. (current time - start time)
12717+
format: date-time
1271912718
lastHeartbeatTime:
1272012719
type: string
1272112720
description: Last heartbeat time, coming from the worker. Worker should set it to "now".
@@ -12781,7 +12780,9 @@ components:
1278112780
format: int32
1278212781
processedTasks:
1278312782
type: integer
12784-
description: Total number of tasks processed by the worker so far.
12783+
description: |-
12784+
Total number of tasks processed (completed both successfully and unsuccesfully)
12785+
by the worker since the worker started. This is a cumulative counter.
1278512786
format: int32
1278612787
failedTasks:
1278712788
type: integer

temporal/api/worker/v1/message.proto

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@ option java_outer_classname = "MessageProto";
99
option ruby_package = "Temporalio::Api::Worker::V1";
1010
option csharp_namespace = "Temporalio.Api.Worker.V1";
1111

12-
13-
import "google/protobuf/duration.proto";
1412
import "google/protobuf/timestamp.proto";
1513
import "temporal/api/deployment/v1/message.proto";
1614
import "temporal/api/enums/v1/common.proto";
@@ -31,7 +29,8 @@ message WorkerSlotsInfo {
3129
// Number of slots used by the worker for specific tasks.
3230
int32 slots_used = 2;
3331

34-
// Total number of tasks processed by the worker so far.
32+
// Total number of tasks processed (completed both successfully and unsuccesfully)
33+
// by the worker since the worker started. This is a cumulative counter.
3534
int32 processed_tasks = 3;
3635
// Total number of failed tasks processed by the worker so far.
3736
int32 failed_tasks = 4;
@@ -60,7 +59,7 @@ message WorkerHostInfo {
6059
message WorkerInfo {
6160
// Worker identifier, should be unique for the namespace.
6261
// It is different from worker identity, which is usually a combination of host_name and process_id.
63-
string worker_id = 1;
62+
string worker_instance_key = 1;
6463

6564
// Worker host information.
6665
WorkerHostInfo host_info = 2;
@@ -76,10 +75,9 @@ message WorkerInfo {
7675
// Worker status. Possible values - "running", "shutting_down", "shutdown".
7776
temporal.api.enums.v1.WorkerStatus status = 7;
7877

79-
// Uptime of the worker, since it started.
80-
// This is the time since the worker started, not the time since the last heartbeat.
81-
// It can be used to determine worker start time. (current time - uptime)
82-
google.protobuf.Duration uptime = 8;
78+
// Worker start time.
79+
// It can be used to determine worker uptime. (current time - start time)
80+
google.protobuf.Timestamp start_time = 8;
8381

8482
// Last heartbeat time, coming from the worker. Worker should set it to "now".
8583
google.protobuf.Timestamp last_heartbeat_time = 9;

temporal/api/workflowservice/v1/request_response.proto

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2376,7 +2376,7 @@ message ListWorkersRequest {
23762376
//* BuildId
23772377
//* SdkName
23782378
//* SdkVersion
2379-
//* Uptime
2379+
//* StartTime
23802380
//* LastHeartbeatTime
23812381
//* Status
23822382
// Currently metrics are not supported as a part of ListWorkers query.

0 commit comments

Comments
 (0)