Skip to content

Comments

Implement Helix API for updating customized state#729

Merged
jiajunwang merged 10 commits intoapache:customizeViewfrom
zhangmeng916:helix-customize-state-api
Feb 26, 2020
Merged

Implement Helix API for updating customized state#729
jiajunwang merged 10 commits intoapache:customizeViewfrom
zhangmeng916:helix-customize-state-api

Conversation

@zhangmeng916
Copy link
Contributor

@zhangmeng916 zhangmeng916 commented Feb 6, 2020

Issues

  • My PR addresses the following Helix issues and references them in the PR description:

(#728 )

Description

  • Here are some details about my PR, including screenshots of any UI changes:

Currently, Helix only supports a single state for every partition. There're increasing requests from customers to have more than one state, which is defined in Helix state model, for their practical use. For example, they may want to have read/write state, quota state, version state, etc. Helix will introduce the concept of customized state, which allows customer to define the states they are interested.
This PR is to implement Helix API for customers to import their customized state. The customized state is adjacent to CURRENT_STATE as a separate znode. Under this znode, there are children znodes representing each individual customized state. And each customized state is categorized by resources.

Tests

  • The following tests are written for this issue:

TestCustomizedStateUpdate.java

  • The following is the result of the "mvn test" command on the appropriate module:

[ERROR] Tests run: 902, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 3,610.949 s <<< FAILURE! - in TestSuite
[ERROR] testWorkflowFailureJobThreshold(org.apache.helix.integration.task.TestJobFailureDependence) Time elapsed: 300.01 s <<< FAILURE!
org.testng.internal.thread.ThreadTimeoutException: Method org.testng.internal.TestNGMethod.testWorkflowFailureJobThreshold() didn't finish within the time-out 300000

[INFO]
[INFO] Results:
[INFO]
[ERROR] Failures:
[ERROR] TestJobFailureDependence.testWorkflowFailureJobThreshold » ThreadTimeout Metho...
[INFO]
[ERROR] Tests run: 902, Failures: 1, Errors: 0, Skipped: 0
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:00 h
[INFO] Finished at: 2020-02-06T09:58:26-08:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:3.0.0-M3:test (default-test) on project helix-core: There are test failures.
[ERROR]
[ERROR] Please refer to /home/mnzhang/helix/helix-core/target/surefire-reports for the individual test results.
[ERROR] Please refer to dump files (if any exist) [date].dump, [date]-jvmRun[N].dump and [date].dumpstream.

Commits

  • My commits all reference appropriate Apache Helix GitHub issues in their subject lines, and I have squashed multiple commits if they address the same issue. In addition, my commits follow the guidelines from "How to write a good git commit message":
    1. Subject is separated from body by a blank line
    2. Subject is limited to 50 characters (not including Jira issue reference)
    3. Subject does not end with a period
    4. Subject uses the imperative mood ("add", not "adding")
    5. Body wraps at 72 characters
    6. Body explains "what" and "why", not "how"

Code Quality

  • My diff has been formatted using helix-style.xml

@zhangmeng916 zhangmeng916 force-pushed the helix-customize-state-api branch 3 times, most recently from 737d708 to d16415b Compare February 6, 2020 20:23
@zhangmeng916 zhangmeng916 force-pushed the helix-customize-state-api branch from 2cde71c to df40d42 Compare February 24, 2020 21:50
Copy link

@alirezazamani alirezazamani left a comment

Choose a reason for hiding this comment

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

Overall LGTM. Please address the comments before merging.

@zhangmeng916
Copy link
Contributor Author

This PR is ready to be merged, approved by @alirezazamani
Final commit message:
Implement Helix APIs in CustomizedStateProvider for customers to operate on their own customized state. The available operations include update, get, and delete. To use CustomizedStateProvider, Helix user should initialize its factory and pass required parameters.

@jiajunwang jiajunwang merged commit 106b069 into apache:customizeView Feb 26, 2020
zhangmeng916 added a commit to zhangmeng916/helix that referenced this pull request Apr 2, 2020
Implement Helix APIs in CustomizedStateProvider for customers to operate on their own customized state. The available operations include update, get, and delete. To use CustomizedStateProvider, Helix user should initialize its factory and pass required parameters.
zhangmeng916 added a commit to zhangmeng916/helix that referenced this pull request Apr 4, 2020
Implement Helix APIs in CustomizedStateProvider for customers to operate on their own customized state. The available operations include update, get, and delete. To use CustomizedStateProvider, Helix user should initialize its factory and pass required parameters.
zhangmeng916 added a commit to zhangmeng916/helix that referenced this pull request Apr 13, 2020
Implement Helix APIs in CustomizedStateProvider for customers to operate on their own customized state. The available operations include update, get, and delete. To use CustomizedStateProvider, Helix user should initialize its factory and pass required parameters.
zhangmeng916 added a commit to zhangmeng916/helix that referenced this pull request Apr 14, 2020
Implement Helix APIs in CustomizedStateProvider for customers to operate on their own customized state. The available operations include update, get, and delete. To use CustomizedStateProvider, Helix user should initialize its factory and pass required parameters.
zhangmeng916 added a commit to zhangmeng916/helix that referenced this pull request Apr 23, 2020
Implement Helix APIs in CustomizedStateProvider for customers to operate on their own customized state. The available operations include update, get, and delete. To use CustomizedStateProvider, Helix user should initialize its factory and pass required parameters.
jiajunwang pushed a commit that referenced this pull request Apr 23, 2020
Implement Helix APIs in CustomizedStateProvider for customers to operate on their own customized state. The available operations include update, get, and delete. To use CustomizedStateProvider, Helix user should initialize its factory and pass required parameters.
huizhilu pushed a commit to huizhilu/helix that referenced this pull request Aug 16, 2020
Implement Helix APIs in CustomizedStateProvider for customers to operate on their own customized state. The available operations include update, get, and delete. To use CustomizedStateProvider, Helix user should initialize its factory and pass required parameters.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants