The Wayback Machine - https://web.archive.org/web/20210101063513/https://github.com/arangodb/arangodb/pull/12594
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/agency cache database subscription #12594

Merged
merged 162 commits into from Sep 28, 2020

Conversation

@kvahed
Copy link
Contributor

@kvahed kvahed commented Sep 2, 2020

Scope & Purpose

(Please describe the changes in this PR for reviewers)

  • 💩 Bugfix
  • 🍕 New feature
  • 🔨 Refactoring
  • 📖 CHANGELOG entry made
  • 💪 The behavior in this PR was manually tested
  • 💻 The behavior change can be verified via automatic tests

Backports:

  • No backports required
  • Backports required for: (Please specify versions)

Related Information

(Please reference tickets / specification etc)

  • Docs PR:
  • Enterprise PR:
  • GitHub issue / Jira ticket number:
  • Design document:

Testing & Verification

(Please pick either of the following options)

  • This change is a trivial rework / code cleanup without any test coverage.
  • This change is already covered by existing tests, such as (please describe tests).
  • This PR adds tests that were used to verify all changes:
    • Added Regression Tests
    • Added new C++ Unit Tests
    • Added new integration tests (i.e. in shell_server / shell_server_aql)
    • Added new resilience tests (only if the feature is impacted by failovers)

Additionally:

  • There are tests in an external testing repository:
  • I ensured this code runs with ASan / TSan or other static verification tools

(Include link to Jenkins run etc)

Documentation

All new Features should be accompanied by corresponding documentation.
Bugs and features should furthermore be documented in the changelog so that
developers and users have a concise overview.

  • Added a Changelog Entry (referencing the corresponding public or internal issue number)
  • Added entry to Release Notes
  • Added a new section in the Manual
  • Added a new section in the HTTP API
  • Added Swagger examples for the HTTP API
  • Updated license information in LICENSES-OTHER-COMPONENTS.md for 3rd party libraries

External contributors / CLA Note

Please note that for legal reasons we require you to sign the Contributor Agreement
before we can accept your pull requests.

@kvahed kvahed added this to the 3.7.3 milestone Sep 2, 2020
@kvahed kvahed requested a review from neunhoef Sep 2, 2020
@kvahed kvahed self-assigned this Sep 2, 2020
Copy link
Contributor

@neunhoef neunhoef left a comment

Some comments. I basically looked at AgencyCache and a few smaller files which seemed ready.

#include "GeneralServer/RestHandler.h"
#include "Scheduler/Scheduler.h"
#include "Scheduler/SchedulerFeature.h"

using namespace arangodb;
using namespace arangodb::consensus;

namespace std {

This comment has been minimized.

@neunhoef

neunhoef Sep 2, 2020
Contributor

Should be unnecessary by std::shared_lock

// Fill existing Builder from readDB, mainly /Plan /Current
index_t AgencyCache::get(VPackBuilder& result, std::string const& path) const {
result.clear();
std::lock_guard g(_storeLock);
std::shared_lock_guard g(_storeLock);

This comment has been minimized.

@neunhoef

neunhoef Sep 2, 2020
Contributor

Just use std::shared_lock

arangod/Cluster/AgencyCache.cpp Show resolved Hide resolved
neunhoef added 2 commits Sep 23, 2020
…-database-subscription
Copy link
Contributor

@neunhoef neunhoef left a comment

LGTM. After the latest changes. However, need to address the TODOs in Maintenance.cpp.

arangod/RestHandler/RestRepairHandler.cpp Outdated Show resolved Hide resolved
arangod/Cluster/AgencyCache.cpp Show resolved Hide resolved
@neunhoef neunhoef merged commit 87b6739 into devel Sep 28, 2020
@neunhoef neunhoef deleted the feature/agency-cache-database-subscription branch Sep 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants
You can’t perform that action at this time.