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

[HUDI-289] Implement a test suite to support long running test for Hudi writing and querying end-end #1100

Merged
merged 1 commit into from Jul 31, 2020

Conversation

yanghua
Copy link
Contributor

@yanghua yanghua commented Dec 12, 2019

  • Flexible schema payload generation
  • Different types of workload generation such as inserts, upserts etc
  • Post process actions to perform validations
  • Interoperability of test suite to use HoodieWriteClient and HoodieDeltaStreamer so both code paths can be tested
  • Custom workload sequence generator
  • Ability to perform parallel operations, such as upsert and compaction

@yanghua yanghua marked this pull request as ready for review December 12, 2019 13:09
@yanghua yanghua changed the title [HUDI-394] Provide a basic implementation of test suite [HUDI-289] Implement a test suite to support long running test for Hudi writing and querying end-end Dec 12, 2019
@yanghua
Copy link
Contributor Author

yanghua commented Dec 12, 2019

I have rebased the old hudi_test_suite_refactor branch based on master (Fixed conflicts and check style errors). From now, let track the work in this PR. FYI @n3nash @vinothchandar

@n3nash
Copy link
Contributor

n3nash commented Dec 17, 2019

@yanghua great, thanks. Can you please take a pass at the current PR and leave any comments that we should address ? Also, lets start running the test suite (I'm doing that too) to see if it works as expected in a longer duration.

* An example of how to generate a workflow dag programmatically. This is also used as the default workflow dag if
* none is provided.
*/
public class WorkflowDagGenerator {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Since this is an example generator. Shall we rename the class name to SimpleWorkflowDagGenerator or DefaultWorkflowDagGenerator? WDYT? @n3nash

Copy link
Contributor

Choose a reason for hiding this comment

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

+1 for SimpleWorkflowDagGenerator

import java.util.List;
import java.util.function.Function;

public class TestComplexDag extends WorkflowDagGenerator {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

IMO, For these classes which do not contain test methods, it would be better to remove the Test prefix. For this class, it could be ComplexDagGenerator. WDYT? @n3nash

Copy link
Contributor

Choose a reason for hiding this comment

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

+1

@yanghua
Copy link
Contributor Author

yanghua commented Dec 20, 2019

Will create an issue in Jira and open a PR to address these changes.

@n3nash
Copy link
Contributor

n3nash commented Dec 23, 2019

@yanghua Can you check why the build is failing now ?

@yanghua
Copy link
Contributor Author

yanghua commented Dec 24, 2019

@yanghua Can you check why the build is failing now ?

I saw the HoodieActiveTimeline#createNewCommitTime has been renamed to HoodieActiveTimeline#createNewInstantTime after merging HUDI-308.

@n3nash
Copy link
Contributor

n3nash commented Dec 25, 2019

@yanghua thanks for fixing the build. Were you able to give the test-suite a try ? That is :

  1. Create your own yaml
  2. Run the TestHudiTestSuiteJob
  3. Run it in docker vs run it in your own spark cluster if you have one

@yanghua
Copy link
Contributor Author

yanghua commented Dec 25, 2019

@yanghua thanks for fixing the build. Were you able to give the test-suite a try ? That is :

  1. Create your own yaml
  2. Run the TestHudiTestSuiteJob
  3. Run it in docker vs run it in your own spark cluster if you have one

OK, will try to run the suite later.

I am trying to integrate it with azure pipelines. Here is a demo: https://dev.azure.com/vinoyang/Hudi/_build

@n3nash
Copy link
Contributor

n3nash commented Jan 7, 2020

@yanghua Left a comment in the other PR

@yanghua
Copy link
Contributor Author

yanghua commented Jan 14, 2020

@n3nash This PR has conflicts, I have rebased.

@n3nash
Copy link
Contributor

n3nash commented Jan 28, 2020

@yanghua please take a look at this PR once you are back from the new year holidays, we should merge this very soon

@n3nash
Copy link
Contributor

n3nash commented Feb 12, 2020

@yanghua merged the pom PR, can you rebase this so we can merge this PR ? I think we have gone through it multiple times, let's have the first version committed so we can come up with more action items around this

@vinothchandar
Copy link
Member

@n3nash @yanghua once ready, please open a PR against master.. Love to do one final review before merging.

@vinothchandar
Copy link
Member

Or is it this PR?

@yanghua
Copy link
Contributor Author

yanghua commented Feb 13, 2020

@yanghua merged the pom PR, can you rebase this so we can merge this PR ? I think we have gone through it multiple times, let's have the first version committed so we can come up with more action items around this

OK, will rebase with the master branch.

@yanghua
Copy link
Contributor Author

yanghua commented Feb 13, 2020

Or is it this PR?

Yes

@vinothchandar
Copy link
Member

sg. In that case, I would like to re-ask my intiial questions again.. How have we validated the framework? are there real tests now? How/when are they run? :)

@yanghua
Copy link
Contributor Author

yanghua commented Feb 13, 2020

sg. In that case, I would like to re-ask my intiial questions again.. How have we validated the framework? are there real tests now? How/when are they run? :)

In my opinion, we will trigger it with azure-pipelines after it merges into master branch.

@yanghua yanghua force-pushed the hudi_test_suite_refactor branch 2 times, most recently from 7a0794a to b04b037 Compare February 13, 2020 14:06
@vinothchandar
Copy link
Member

How have we validated the framework? are there real tests now?

Can you also please answer these?

@yanghua
Copy link
Contributor Author

yanghua commented Feb 14, 2020

How have we validated the framework? are there real tests now?

Can you also please answer these?

We validate the test suite via running the unit tests and e2e tests(TestHoodieTestSuiteJob) by local, Travis and docker. There is one mock test here1. About real tests, do you mean how to validate all the functions of hudi via this test suite?

@n3nash n3nash force-pushed the hudi_test_suite_refactor branch 12 times, most recently from 5cdfbe0 to 8980e09 Compare July 20, 2020 22:57
Copy link
Member

@vinothchandar vinothchandar left a comment

Choose a reason for hiding this comment

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

Just one small comment. Let's land and iterate. This is in good shape now for us I think
Thanks @yanghua @n3nash for your tireless efforts here.

@n3nash please go ahead and land once CI is all happy.

@@ -125,6 +125,10 @@
<artifactId>mockito-junit-jupiter</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-junit-jupiter</artifactId>
Copy link
Member

Choose a reason for hiding this comment

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

yes.. lets remove this.. may be a rebase/merge thing?

@n3nash n3nash force-pushed the hudi_test_suite_refactor branch 5 times, most recently from 7cc6c55 to 9e9f930 Compare July 28, 2020 05:57
@n3nash n3nash force-pushed the hudi_test_suite_refactor branch 6 times, most recently from f651091 to aadba78 Compare July 30, 2020 17:59
@n3nash n3nash merged commit 2fc2b01 into master Jul 31, 2020
@vinothchandar vinothchandar deleted the hudi_test_suite_refactor branch May 10, 2021 21:51
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.

None yet

7 participants