Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

provide a response description for supervisor status api #15031

Closed

Conversation

sergioferragut
Copy link
Contributor

Description

Provides a description for the response to the supervisor status API.

This PR has:

  • [ X ] been self-reviewed.
  • [ X ] added documentation for new or modified features or behaviors.
  • a release note entry in the PR description.
  • added Javadocs for most classes and all non-trivial methods. Linked related entities via Javadoc links.
  • added or updated version, license, or notice information in licenses.yaml
  • added comments explaining the "why" and the intent of the code wherever would not be obvious for an unfamiliar reader.
  • added unit tests or modified existing tests to cover new code paths, ensuring the threshold for code coverage is met.
  • added integration tests.
  • been tested in a test Druid cluster.

@sergioferragut sergioferragut marked this pull request as ready for review September 22, 2023 21:37
@@ -1311,6 +1311,29 @@ Host: http://ROUTER_IP:ROUTER_PORT
```
</details>

#### Response Description
The response `payload` contains the following structure:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The response `payload` contains the following structure:
The response `payload` contains the following properties:

|Property|Type|Description|
|---|---|---|
|`dataSource`|String|The target datasource.|
|`stream`|String|Name of the topic or stream that the ingestion is reading from.|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
|`stream`|String|Name of the topic or stream that the ingestion is reading from.|
|`stream`|String|The name of the topic or stream that the ingestion is reading from.|

|---|---|---|
|`dataSource`|String|The target datasource.|
|`stream`|String|Name of the topic or stream that the ingestion is reading from.|
|`partitions`|Integer|Number of partitions in the source stream.|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
|`partitions`|Integer|Number of partitions in the source stream.|
|`partitions`|Integer|The number of partitions in the source stream.|

|`dataSource`|String|The target datasource.|
|`stream`|String|Name of the topic or stream that the ingestion is reading from.|
|`partitions`|Integer|Number of partitions in the source stream.|
|`replicas`|Integer|Number of replicas being used per task for high availability where 1 means no redundancy.|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
|`replicas`|Integer|Number of replicas being used per task for high availability where 1 means no redundancy.|
|`replicas`|Integer|The number of replicas being used per task for high availability where 1 means no redundancy.|

|`stream`|String|Name of the topic or stream that the ingestion is reading from.|
|`partitions`|Integer|Number of partitions in the source stream.|
|`replicas`|Integer|Number of replicas being used per task for high availability where 1 means no redundancy.|
|`durationSeconds`|Integer|Seconds that each task spends reading before moving to a publishing state.|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
|`durationSeconds`|Integer|Seconds that each task spends reading before moving to a publishing state.|
|`durationSeconds`|Integer|The number of seconds that each task spends reading before moving to a publishing state.|

|`replicas`|Integer|Number of replicas being used per task for high availability where 1 means no redundancy.|
|`durationSeconds`|Integer|Seconds that each task spends reading before moving to a publishing state.|
|`activeTasks`|Array of Object|Lists the tasks that are reading from the stream, each with: <table><tbody><tr><td>`startTime`</td><td>String</td><td>Task start time.</td></tr><tr><td>`remainingTime`</td><td>Integer</td><td>The time remaining in the reading state</td><tr><tr><td>`currentOffsets`</td><td>Map < String , Integer ></td><td>The list of partitions that the task is reading from with the latest offset consumed from each.</td></tr><tr><td>`lag`</td><td>Map < String , Integer ></td><td>The number of messages pending to read from each partition.</td></tr></tbody></table> |
|`publishingTasks`|Array of Object|Lists the tasks that are publishing segments to Deep Storage and awaiting handoff confirmation. For detailed structure see `activeTasks` above.|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
|`publishingTasks`|Array of Object|Lists the tasks that are publishing segments to Deep Storage and awaiting handoff confirmation. For detailed structure see `activeTasks` above.|
|`publishingTasks`|Array of objects|Lists the tasks that are publishing segments to Deep Storage and awaiting handoff confirmation. For detailed structure see `activeTasks` above.|

|`activeTasks`|Array of Object|Lists the tasks that are reading from the stream, each with: <table><tbody><tr><td>`startTime`</td><td>String</td><td>Task start time.</td></tr><tr><td>`remainingTime`</td><td>Integer</td><td>The time remaining in the reading state</td><tr><tr><td>`currentOffsets`</td><td>Map < String , Integer ></td><td>The list of partitions that the task is reading from with the latest offset consumed from each.</td></tr><tr><td>`lag`</td><td>Map < String , Integer ></td><td>The number of messages pending to read from each partition.</td></tr></tbody></table> |
|`publishingTasks`|Array of Object|Lists the tasks that are publishing segments to Deep Storage and awaiting handoff confirmation. For detailed structure see `activeTasks` above.|
|`latestOffsets`|Map < String, Integer >|The lastest offset consumed from the stream by partition.|
|`minimumLag`|Map < String, Integer >|The number of messages pending to read from stream by partition.|
Copy link
Contributor

@ektravel ektravel Nov 1, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
|`minimumLag`|Map < String, Integer >|The number of messages pending to read from stream by partition.|
|`minimumLag`|`Map < String, Integer >`|The number of messages pending to read from the stream by partition.|

Should the Map interface be in code font?

|`latestOffsets`|Map < String, Integer >|The lastest offset consumed from the stream by partition.|
|`minimumLag`|Map < String, Integer >|The number of messages pending to read from stream by partition.|
|`aggregateLag`|Integer|The sum of minimum lags (see above) across all partitions.|
|`offsetLastUpdated`|String|Contains the timestamp of when the stream offsets were last inspected.|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
|`offsetLastUpdated`|String|Contains the timestamp of when the stream offsets were last inspected.|
|`offsetLastUpdated`|String|The timestamp of when the stream offsets were last inspected.|

|`minimumLag`|Map < String, Integer >|The number of messages pending to read from stream by partition.|
|`aggregateLag`|Integer|The sum of minimum lags (see above) across all partitions.|
|`offsetLastUpdated`|String|Contains the timestamp of when the stream offsets were last inspected.|
|`suspended`|Boolean|True if the supervisor is in a SUSPENDED state.|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
|`suspended`|Boolean|True if the supervisor is in a SUSPENDED state.|
|`suspended`|Boolean|True if the supervisor is in a `SUSPENDED` state.|

|`suspended`|Boolean|True if the supervisor is in a SUSPENDED state.|
|`healthy`|Boolean|True if the supervisor and its tasks are currently healthy.|
|`state`|String|Overall state of the supervisor. |
|`detailedState`|String|Current stage of processing for the supervisor.|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
|`detailedState`|String|Current stage of processing for the supervisor.|
|`detailedState`|String|Current stage of processing for the supervisor.|

Should this say "state" instead of "stage"?

|`healthy`|Boolean|True if the supervisor and its tasks are currently healthy.|
|`state`|String|Overall state of the supervisor. |
|`detailedState`|String|Current stage of processing for the supervisor.|
|`recentErrors`|Array of String|Errors reported recently by supervisor managed tasks.|
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
|`recentErrors`|Array of String|Errors reported recently by supervisor managed tasks.|
|`recentErrors`|Array of strings|Errors reported recently by supervisor managed tasks.|

|`partitions`|Integer|Number of partitions in the source stream.|
|`replicas`|Integer|Number of replicas being used per task for high availability where 1 means no redundancy.|
|`durationSeconds`|Integer|Seconds that each task spends reading before moving to a publishing state.|
|`activeTasks`|Array of Object|Lists the tasks that are reading from the stream, each with: <table><tbody><tr><td>`startTime`</td><td>String</td><td>Task start time.</td></tr><tr><td>`remainingTime`</td><td>Integer</td><td>The time remaining in the reading state</td><tr><tr><td>`currentOffsets`</td><td>Map < String , Integer ></td><td>The list of partitions that the task is reading from with the latest offset consumed from each.</td></tr><tr><td>`lag`</td><td>Map < String , Integer ></td><td>The number of messages pending to read from each partition.</td></tr></tbody></table> |
Copy link
Contributor

@ektravel ektravel Nov 1, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of a nested table, consider creating a separate table for activeTasks properties.

Also, the Map interface should probably be in code font.

Copy link
Contributor

@ektravel ektravel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left some suggestions. Also, I think "array of objects" reads better than "array of object". Unless "array of object" is the correct way of referring to array values.

Copy link

github-actions bot commented Mar 5, 2024

This pull request has been marked as stale due to 60 days of inactivity.
It will be closed in 4 weeks if no further activity occurs. If you think
that's incorrect or this pull request should instead be reviewed, please simply
write any comment. Even if closed, you can still revive the PR at any time or
discuss it on the dev@druid.apache.org list.
Thank you for your contributions.

@github-actions github-actions bot added the stale label Mar 5, 2024
Copy link

github-actions bot commented Apr 3, 2024

This pull request/issue has been closed due to lack of activity. If you think that
is incorrect, or the pull request requires review, you can revive the PR at any time.

@github-actions github-actions bot closed this Apr 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants