-
Notifications
You must be signed in to change notification settings - Fork 164
[RORDEV-1857] Fix for Windows-based CI jobs #1185
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
Conversation
...main/scala/tech/beshu/ror/tools/core/patches/internal/filePatchers/JarManifestModifier.scala
Show resolved
Hide resolved
tests-utils/src/main/scala/tech/beshu/ror/utils/gradle/RorPluginGradleProject.scala
Show resolved
Hide resolved
This comment was marked as resolved.
This comment was marked as resolved.
tests-utils/src/main/scala/tech/beshu/ror/utils/containers/windows/WindowsEsSetup.scala
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (1)
tests-utils/src/main/scala/tech/beshu/ror/utils/misc/ScalaUtils.scala (1)
78-100: Consider renaming thetimesparameter for clarity.The parameter name
timescould be ambiguous. The implementation treats it as the total number of attempts (not retries), so callingretry(3, ...)makes 3 attempts total. Consider renaming tomaxAttemptsto clarify this behavior.Example:
-def retry(times: Int, cleanBeforeRetrying: => Unit = ())(action: => Unit): Unit = { +def retry(maxAttempts: Int, cleanBeforeRetrying: => Unit = ())(action: => Unit): Unit = {
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
Disabled knowledge base sources:
- Jira integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (4)
tests-utils/src/main/scala/tech/beshu/ror/utils/containers/windows/WindowsEsDirectoryManager.scala(1 hunks)tests-utils/src/main/scala/tech/beshu/ror/utils/containers/windows/WindowsEsSetup.scala(2 hunks)tests-utils/src/main/scala/tech/beshu/ror/utils/misc/EsStartupChecker.scala(2 hunks)tests-utils/src/main/scala/tech/beshu/ror/utils/misc/ScalaUtils.scala(2 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
- tests-utils/src/main/scala/tech/beshu/ror/utils/containers/windows/WindowsEsDirectoryManager.scala
- tests-utils/src/main/scala/tech/beshu/ror/utils/containers/windows/WindowsEsSetup.scala
🧰 Additional context used
🧬 Code graph analysis (1)
tests-utils/src/main/scala/tech/beshu/ror/utils/misc/EsStartupChecker.scala (1)
tests-utils/src/main/scala/tech/beshu/ror/utils/misc/ScalaUtils.scala (2)
ScalaUtils(31-132)retryBackoff(102-114)
🔇 Additional comments (4)
tests-utils/src/main/scala/tech/beshu/ror/utils/misc/EsStartupChecker.scala (2)
28-28: LGTM!Clean import enabling use of the centralized retry utility.
39-39: LGTM! Linear retry strategy confirmed.The
backOffScaler = 1parameter means the delay stays constant at 2 seconds (no exponential increase). This appears intentional to maintain the original behavior. Total wait time aligns with the 5-minute timeout on line 42.tests-utils/src/main/scala/tech/beshu/ror/utils/misc/ScalaUtils.scala (2)
87-94: Logging verbosity is high but acceptable for test utilities.Each retry logs the full exception stack trace (line 90), which can be quite verbose. However, given this is in test utilities and the PR aims to debug CI issues, this level of detail is likely intentional and helpful for troubleshooting intermittent failures.
22-31: TheTryimport is actively used—no change needed.Line 45 uses
Try(format.parse(value)).toOption.isDefined, confirming the import on line 29 is necessary.Likely an incorrect or invalid review comment.
tests-utils/src/main/scala/tech/beshu/ror/utils/misc/ScalaUtils.scala
Outdated
Show resolved
Hide resolved
coutoPL
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Fix for WIndows-based CI jobs. Added retrying, when the downloaded ES zip is somehow corrupted or for any other reason cannot be unzipped.
Summary by CodeRabbit
Bug Fixes
New Features
Chores