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

fix: ensure custom endpoint monitor obeys refresh rate #1175

Merged
merged 6 commits into from
Nov 7, 2024

Conversation

aaron-congo
Copy link
Contributor

Description

  • Math.min was mistakenly used where Math.max should have been used, resulting in the custom endpoint monitor never sleeping. This PR corrects the logic so that the monitor obeys sleeps according to the refresh rate
  • also includes some other minor fixes and cleans up the custom endpoint test

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@aaron-congo aaron-congo changed the title Fix: ensure custom endpoint monitor obeys refresh rate fix: ensure custom endpoint monitor obeys refresh rate Nov 1, 2024
waitUntilEndpointsDeleted(client);
}

private static void waitUntilEndpointsDeleted(RdsClient client) {
Copy link
Contributor Author

@aaron-congo aaron-congo Nov 1, 2024

Choose a reason for hiding this comment

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

This used to be called after deleting the test custom endpoint after all tests in the file had been completed. I removed it to save some time (note that the custom endpoint still gets deleted, we are just no longer waiting for it to fully complete the deletion). Each custom endpoint will have a unique ID, so even though other tests could start running while the custom endpoint is still being deleted, no other tests should be require it to be fully deleted before running. Let me know if you think I should add it back

Copy link

github-actions bot commented Nov 1, 2024

Qodana Community for JVM

It seems all right 👌

No new problems were found according to the checks applied

💡 Qodana analysis was run in the pull request mode: only the changed files were checked

View the detailed Qodana report

To be able to view the detailed Qodana report, you can either:

  1. Register at Qodana Cloud and configure the action
  2. Use GitHub Code Scanning with Qodana
  3. Host Qodana report at GitHub Pages
  4. Inspect and use qodana.sarif.json (see the Qodana SARIF format for details)

To get *.log files or any other Qodana artifacts, run the action with upload-result option set to true,
so that the action will upload the files as the job artifacts:

      - name: 'Qodana Scan'
        uses: JetBrains/[email protected]
        with:
          upload-result: true
Contact Qodana team

Contact us at [email protected]

@@ -188,13 +186,18 @@ public void run() {
}
}
} catch (InterruptedException e) {
LOGGER.info(Messages.get("CustomEndpointMonitorImpl.interrupted", new Object[]{ this.customEndpointHostSpec }));
LOGGER.info(
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: Log level fine is probably better in this case.

@aaron-congo aaron-congo merged commit 0ab71cd into main Nov 7, 2024
6 checks passed
@aaron-congo aaron-congo deleted the fix-custom-endpoint-refresh-rate branch November 7, 2024 18:15
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.

2 participants