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

Implement blue/green deployment support in REPL mode #141

Merged
merged 3 commits into from
Nov 11, 2023
Merged

Implement blue/green deployment support in REPL mode #141

merged 3 commits into from
Nov 11, 2023

Conversation

kaituo
Copy link
Collaborator

@kaituo kaituo commented Nov 8, 2023

Description

Features:

  • Add mutual exclusivity in session-based emr-s jobs to ensure only one job runs at a time, enhancing system stability during blue/green deployments. This allows active job exclusion and seamless task pickup by new jobs. Details in [FEATURE] REPL Job support Blue/Green upgrade #94.

Fixes:

  • Resolve a bug where long-running queries failed to cancel post-index mapping verification, by introducing timely query cancellation checks within the REPL loop.
  • Address issue [BUG] Skipping Index does not apply to direct query #138 with the proposed short-term fix, improving reliability.

Tests:

  • Conducted manual testing to validate blue/green deployment support and query cancellation.
  • Extended unit tests to cover new features and bug fixes.

Issues Resolved

#138
#94

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Features:
- Add mutual exclusivity in session-based emr-s jobs to ensure only one job runs at a time, enhancing system stability during blue/green deployments. This allows active job exclusion and seamless task pickup by new jobs. Details in #94.

Fixes:
- Resolve a bug where long-running queries failed to cancel post-index mapping verification, by introducing timely query cancellation checks within the REPL loop.
- Address issue #138 with the proposed short-term fix, improving reliability.

Tests:
- Conducted manual testing to validate blue/green deployment support and query cancellation.
- Extended unit tests to cover new features and bug fixes.

Signed-off-by: Kaituo Li <kaituo@amazon.com>
Signed-off-by: Kaituo Li <kaituo@amazon.com>
Copy link
Collaborator

@penghuo penghuo left a comment

Choose a reason for hiding this comment

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

could we make following value configurable. i found with 2 executors, some query can not finish by 10mins, but just in case user want to override it.

private val INACTIVITY_LIMIT_MILLIS = 30 * 60 * 1000
private val QUERY_EXECUTION_TIMEOUT = Duration(10, MINUTES)
private val QUERY_WAIT_TIMEOUT_MILLIS = 10 * 60 * 1000

Signed-off-by: Kaituo Li <kaituo@amazon.com>
@kaituo
Copy link
Collaborator Author

kaituo commented Nov 11, 2023

could we make following value configurable. i found with 2 executors, some query can not finish by 10mins, but just in case user want to override it.

private val INACTIVITY_LIMIT_MILLIS = 30 * 60 * 1000 private val QUERY_EXECUTION_TIMEOUT = Duration(10, MINUTES) private val QUERY_WAIT_TIMEOUT_MILLIS = 10 * 60 * 1000

changed.

| }
| }
| ]
| }
|}""".stripMargin

Copy link
Collaborator

Choose a reason for hiding this comment

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

  1. state should be waiting.
  2. what if plugin cancel statement, but queryLoop use scroll search, the statement in scroll context still waiting state.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

  1. Can you explain a bit? Are you asking where I search for waiting state
        "term": {
          "state": "waiting"
        }
      },
  1. Yeah, we need to change to not to use scroll search.

@penghuo penghuo merged commit 1f31e56 into main Nov 11, 2023
5 checks passed
@kaituo kaituo deleted the bg branch November 28, 2023 09:41
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