-
Notifications
You must be signed in to change notification settings - Fork 277
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
[FEATURE] Introduce the smoke test for OpenSearch distribution + plugins #4551
Comments
@peternied @Gaganjuneja fyi, @peterzhuamazon could you please add a few hints where to look at for implementing such a feature, thank you. |
Have a discussion with @reta offline and introduced him on the current build repo test_workflow status. Send this link: https://github.com/opensearch-project/opensearch-build/tree/main/src/test_workflow Thanks. |
Here is the wiki with some details on the testing: https://github.com/opensearch-project/opensearch-build/wiki/Testing-the-Distribution @reta Wondering what we are trying to achieve here? Please correct me if I am wrong, do you want to run integration test at the distribution level even in the plugin CI? |
Thanks @gaiksaya ! No, I was thinking of running integration test at the distribution level with all (or at least most) of the plugins installed. The reasoning here is that we do have a few plugins now that affect OpenSearch core and every other plugin out there (indirectly or not) like |
So that is pretty much what we are doing right now, but change to specific plugins or test cases, right? We are already running each plugin integTest while deploying full bundled distribution. |
Correct, but the integTest in this case won't be focused on any specific plugin but distribution, I was thinking about just 1-2 core flows (like index + search fe), to make sure the distribution + plugins are working fine. |
The TL;DR of the integration test workflow is: Install the recently created distribution (min + plugins) into the VM. Clone the plugin repository, checkout a specific commit/branch used to build the above distribution and then run this https://github.com/opensearch-project/opensearch-build/blob/main/scripts/default/integtest.sh#L105 I believe you want the same for OpenSearch too? (min+plugins) and then run Also heads-up we do not have any integration test for the distribution ONLY as such at this point. We do have validation that makes sure basic APIs like health and plugin list runs, but as such no integration tests for "OpenSearch as a Distribution" |
I think yes, I will look shortly but is sounds about right: install min, install plugins, run 1-2 tests
Correct, this is why this issue was created |
Got it now! Thank you for being patient and helping us understand.
|
I was thinking about build repo, may be we could simplify it by using
I think if we want keep tests in OpenSearch repo (not build repo), we could repurpose some existing tests and run them as run gradle check at the distribution level |
I believe so. We can either expand the validation workflow API test cases here or add new framework for integration testing at the distribution level separately.
Right! I believe this is another problem we are trying to solve. Onboarding OpenSearch to test workflow can be another problem statement. I assumed if this repurposing was to add the integration tests at distribution level then it would be beneficial to get everything in one go. Adding @prudhvigodithi @bbarani to this conversation to provide some insights and let us know if any parallel efforts are going on. |
👍 will look into it
👍 will look what we have now (we have a lot of test types and phases) |
Reading the above comments what we can do is.
If we dont want this in build repo we can even have a new repo for this distribution level testing, something like https://github.com/opensearch-project/opensearch-dashboards-functional-test which should be common for both OpenSearch and OpenSearch Dashboards. @reta is this something you are looking for ? :) |
Thanks @prudhvigodithi , I think your comment incorporates possible directions for improving / evolving the validation part of the build, I currently have no knowledge of it (but the hints where to look, thanks to @gaiksaya ). At high level - I am looking for very specific phase at the validation step when we could:
The last step is not specific to any plugin but a distribution as a cohesive bundle. |
We already do 1-2 so only part we need to add is |
functional test repo is design for smoke test purpose (or we named it release test) for dashboards and dashboards plugin :) |
[Grooming]
|
We plan to create a new test workflow framework for smoke tests. The main uncertainty we have now is how we define smoke tests. Here are some of Scope and Requirements we were thinking:
In this way, we would be focusing on testing the basic functionalities including API status verification for OpenSearch core and plugins with a distribution bundle spun up. What do you think about any of specific smoke tests (any API requests) from Core perspective that we could start on? @reta |
Thanks @zelinh , it makes perfect sense
I think as per comment:
That would be great start. I sadly don't know if we already have such tests (as part of plugin suites) in some form or another, but that was an idea: install all plugins, ingest few documents, run search. I think we don't need many tests. Does it answer your question? |
In our validation workflow the most we did was to call 9200/5601 port, list plugin, check cluster status and that is it. I assume we need to call more APIs as a baseline to see if the cluster is good. |
Correct, ingest + search for ingested docs |
Make sense for me. We could start with ingesting few docs and run some basic search on indices. The framework we design could also be elaborated with time. |
We proposed smoke test workflow provides a foundational framework to run quick checks on the OpenSearch bundle. These tests run separately from the more complex integration tests but follow a similar deployment process. Introduce a smoke test framework to the CI/CD process. The workflow will pass parameters like the distribution path, architecture, and components. Tasks:
|
Thanks for the update @zelinh
I think in general it makes sense but we very likely don't need that at first: the initial smoke test to run, as we discussed, has a goal of making sure basic ingestion + search work with all plugins installed. This flow (again, in basic form) does not directly depend on any plugin. |
Is your feature request related to a problem? Please describe
The OpenSearch distribution build has extensive support of running integration tests (integtest.sh) per individual components (mostly plugins at the moment) but not for a distribution with all plugins installed.
Describe the solution you'd like
It would be great to run a limited amount of amount of smoke tests for distribution with all plugins installed. The issue basically came out of opensearch-project/security#4003, and in nutshell is:
security
,performance-analyzer
) rely on internals of the OpenSearchtelemetry
) introduce additional instrumentation / wrapping around these internalsHaving a full distribution and running a few tests to make sure key functional parts work would be sufficient to catch such issues early on.
Describe alternatives you've considered
Add integration tests to each plugin repo separately
Additional context
The text was updated successfully, but these errors were encountered: