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

Refactor QueryRegistry #18424

Merged
merged 4 commits into from
Mar 28, 2023
Merged

Refactor QueryRegistry #18424

merged 4 commits into from
Mar 28, 2023

Conversation

mpoeter
Copy link
Contributor

@mpoeter mpoeter commented Mar 23, 2023

Scope & Purpose

... and cleanup killed/finished queries as soon as the last engine is closed.

  • 🔨 Refactoring/simplification

Checklist

  • Tests
    • Regression tests
    • C++ Unit tests
    • integration tests
    • resilience tests
  • 📖 CHANGELOG entry made

@cla-bot cla-bot bot added the cla-signed label Mar 23, 2023
@MBkkt MBkkt self-requested a review March 23, 2023 18:25
Copy link
Contributor

@MBkkt MBkkt left a comment

Choose a reason for hiding this comment

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

will be nice if it simplify or get rid of usage QueryRegister in DatabaseFeature

@mpoeter mpoeter marked this pull request as ready for review March 24, 2023 14:40
@jsteemann jsteemann added this to the devel milestone Mar 24, 2023
@@ -819,8 +813,6 @@ RestStatus RestAqlHandler::handleFinishQuery(std::string const& idString) {
TRI_ERROR_HTTP_NOT_FOUND);
return {};
}

_queryRegistry->destroyQuery(_vocbase.name(), qid, errorCode);
Copy link
Contributor

Choose a reason for hiding this comment

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

I guess this extra call to destroyQuery(...) was superfluous before, and it was intentionally removed.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

finishQuery now implicitly destroys the query, that's why this call is no longer needed.

Copy link
Contributor

@jsteemann jsteemann left a comment

Choose a reason for hiding this comment

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

LGTM

@jsteemann jsteemann merged commit 261b8dc into devel Mar 28, 2023
@jsteemann jsteemann deleted the chore/refactor-query-registry branch March 28, 2023 08:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants