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

Adding MLTask #24

Merged
merged 5 commits into from
May 6, 2021
Merged

Adding MLTask #24

merged 5 commits into from
May 6, 2021

Conversation

zhanghg08
Copy link

Description

Add MLTask data model to model ML request(train/predict). Later this MLTask will be used in following scenarios:

  • MLTaskManager will store MLTask and update state based on ML running result/fault
  • When dispatching new request, MLTaskRunner will check # of MLTask running on each node to help make decision

Issues Resolved

Part of task and resource management

Check List

  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@zhanghg08 zhanghg08 changed the title Task Adding MLTask May 6, 2021
Adjust taskType and state to use Enum type.
Comment on lines 28 to 46
@Getter
private final String taskId;

@Getter
private final MLTaskType taskType;

@Setter
@Getter
private MLTaskState state;

@Getter
private final Instant createTime;

@Getter
private final String modelId;

@Setter
@Getter
private String error;
Copy link
Contributor

Choose a reason for hiding this comment

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

Minor: move @Getter to above class definition to simplify the Getter annotation

Copy link
Contributor

Choose a reason for hiding this comment

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

For this string error, not sure if it can meet our use case or not. we can keep it this way now and refactor it later when needed

@zhanghg08 zhanghg08 merged commit 69e1eb1 into opensearch-project:develop May 6, 2021
jackiehanyang pushed a commit that referenced this pull request Nov 16, 2021
* Add MLTask data model.

* Align task type

* Modify MLTaskTest case

* Add error field to store failure message
Adjust taskType and state to use Enum type.

* Move @Getter to class level
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants