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

control-service: integration test for async job deploy #2829

Merged
merged 22 commits into from
Nov 9, 2023

Conversation

mrMoZ1
Copy link
Contributor

@mrMoZ1 mrMoZ1 commented Oct 24, 2023

what: Add integration test that checks the status of the database when using the new data jobs deployment synchronizer.

why: part of the https://github.com/vmware/versatile-data-kit/tree/main/specs/vep-2272-complete-data-job-configuration-persistence VEP

testing: n/a

mrMoZ1 and others added 2 commits October 24, 2023 10:23
@mrMoZ1 mrMoZ1 changed the title control-service:integration test for async deploy control-service: integration test for async job deploy Oct 24, 2023
Momchil Z added 3 commits October 24, 2023 10:31
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
@mivanov1988
Copy link
Collaborator

As we discussed the test had to be reworked as per @antoniivanov 's comment - #2781 (comment), but I don't think this is the case. Also, you should verify all deployment fields not just 3-4 after each operation through the APIs.

mrMoZ1 and others added 8 commits October 24, 2023 16:32
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
@mrMoZ1
Copy link
Contributor Author

mrMoZ1 commented Oct 25, 2023

As we discussed the test had to be reworked as per @antoniivanov 's comment - #2781 (comment), but I don't think this is the case. Also, you should verify all deployment fields not just 3-4 after each operation through the APIs.

The test couldn't be refactored into multiple smaller test cases, since there is apparently some intrinsic state that is lost when executing different test cases. I refactored the larger test cases to call different methods (which were supposed to be ordered tests) and it works that way. When I try to make them into different test cases they fail.

I am also checking all fields except for resources - since they aren't supported yet and if I set them via the POST request the test fails :

private void validateJobResources(DataJobDeployment dataJobDeployment) {
if (dataJobDeployment != null
&& dataJobDeployment.getResources() != null
&& (dataJobDeployment.getResources().getCpuRequest() != null
|| dataJobDeployment.getResources().getCpuLimit() != null
|| dataJobDeployment.getResources().getMemoryRequest() != null
&& dataJobDeployment.getResources().getMemoryLimit() != null)) {
throw new ValidationException(
"The setting of job resources like CPU and memory is not allowed.",
"The setting of job resources like CPU and memory is not supported by the platform.",
"The deployment of the data job will not proceed.",
"To deploy the data job, please do not configure job resources.");
}
}
}

mrMoZ1 and others added 5 commits October 27, 2023 00:46
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
mrMoZ1 added 2 commits November 8, 2023 16:22
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
@mrMoZ1 mrMoZ1 merged commit 2586751 into main Nov 9, 2023
8 checks passed
@mrMoZ1 mrMoZ1 deleted the person/mzhivkov/integration-tst branch November 9, 2023 15:36
yonitoo pushed a commit that referenced this pull request Nov 13, 2023
what: Add integration test that checks the status of the database when
using the new data jobs deployment synchronizer.

why: part of the
https://github.com/vmware/versatile-data-kit/tree/main/specs/vep-2272-complete-data-job-configuration-persistence
VEP

testing: n/a

---------

Signed-off-by: mrMoZ1 <mzhivkov@vmware.com>
Co-authored-by: github-actions <>
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.

4 participants