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

[Feature] Add ability to run test scenarios in the Jenkins runner environment #4622

Open
cwperks opened this issue Apr 3, 2024 · 3 comments
Labels
enhancement New Enhancement

Comments

@cwperks
Copy link
Member

cwperks commented Apr 3, 2024

Is your feature request related to a problem? Please describe

I would like to have the ability to run a single test, test suite or gradle test task in the Jenkins runner multiple times to help reproduce and minimize flaky tests. When looking at various flaky test issues, I run the test locally multiple times and the tests pass every time making it harder to simulate the conditions that led to failure on a CI check.

Describe the solution you'd like

When looking at flaky test issues, it could be helpful to run the tests on the Jenkins runner (or any Github runner) to simulate similar conditions that led to failure. I'd like the ability to not run the full gradle check, but rather a single test, test suite or gradle test task (like :server:test) without running the full gradle check.

Related component

Build

Describe alternatives you've considered

Continue to try to reproduce locally or on remote instances of different os types.

Additional context

The security plugin added a RepeatRule to help with local testing for diagnosing flaky tests. It would be helpful to have something similar and have it run on the Jenkins instances or a Github Runner.

@cwperks cwperks added enhancement New Enhancement untriaged Issues that have not yet been triaged labels Apr 3, 2024
@peternied peternied changed the title [Feature] Add ability to run a single test, single test suite, or gradle test task n times on a fork with the Jenkins runner [Feature] Add ability to run test scenarios in the Jenkins runner environment Apr 10, 2024
@peternied
Copy link
Member

@opensearch-project/admin Can you transfer this to opensearch-build? This seems like a feature of how the jenkins job can be run or scheduled

@bbarani bbarani transferred this issue from opensearch-project/OpenSearch Apr 10, 2024
@prudhvigodithi
Copy link
Member

prudhvigodithi commented May 9, 2024

[Triage]
Thanks @cwperks, to have an ability to run a job in Jenkins requires a job execution access for a user and the best way to do it is to have a mechanism for Jenkins to be able to login with GitHub and the restricted GitHub users can be part of the job execution role, but even with this it would be limited to only restricted users. The entire build/test jobs are all reproducible locally (with or without the same docker images used in Jenkins) @cwperks may I please know what are the challenges when ran locally? is it the compute limits ?
Also ya its a good idea to run the targeted test in gradle check as required (even during the PR creation), but at this point since the only test for Core is the gradle check its not targeted at the test level rather a full blown gradle check is executed for every PR and post merge actions. I'm happy to see and contribute to reduce the flakiness and time takes to run the gradle check.

Thank you
@gaiksaya @rishabh6788 @peterzhuamazon @bbarani

@prudhvigodithi prudhvigodithi removed the untriaged Issues that have not yet been triaged label May 9, 2024
@bbarani
Copy link
Member

bbarani commented May 9, 2024

@cwperks As mentioned by @prudhvigodithi you can setup your own Jenkins instance by following the steps mentioned here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New Enhancement
Projects
Status: 📦 Backlog
Development

No branches or pull requests

4 participants