-
Notifications
You must be signed in to change notification settings - Fork 153
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
adds helper function to check for an arango collection index #1750
adds helper function to check for an arango collection index #1750
Conversation
Signed-off-by: Anirudh Edpuganti <aedpuganti@guidewire.com> adds index struct to hold index data Signed-off-by: Amit Singh <singhamitch@outlook.com> adds func that returns full collection index mapping Signed-off-by: Amit Singh <singhamitch@outlook.com> adds logic to conditionally create collectionn indexes Signed-off-by: Amit Singh <amisingh@guidewire.com> removes todo Signed-off-by: Amit Singh <amisingh@guidewire.com> checks for missing vertex collection and creates them Signed-off-by: Anirudh Edpuganti <aniedpuganti@gmail.com> ignores existing primary index Signed-off-by: Amit Singh <singhamitch@outlook.com> minor refactor Signed-off-by: Amit Singh <singhamitch@outlook.com> minor refactor Signed-off-by: Anirudh Edpuganti <aniedpuganti@gmail.com>
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.
@semmet95 Added some comments. Thanks for the PR!
Signed-off-by: Amit Singh <singhamitch@outlook.com>
@pxp928 Implemented all the suggestions |
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.
Overall this looks good to me, but I'm wondering whether we should check errors in all places where we call a function that can error
Signed-off-by: Amit Singh <amisingh@guidewire.com>
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! Thanks @semmet95!
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.
Thank you!
…#1750) * adds helper function to check for an arango collection index Signed-off-by: Anirudh Edpuganti <aedpuganti@guidewire.com> adds index struct to hold index data Signed-off-by: Amit Singh <singhamitch@outlook.com> adds func that returns full collection index mapping Signed-off-by: Amit Singh <singhamitch@outlook.com> adds logic to conditionally create collectionn indexes Signed-off-by: Amit Singh <amisingh@guidewire.com> removes todo Signed-off-by: Amit Singh <amisingh@guidewire.com> checks for missing vertex collection and creates them Signed-off-by: Anirudh Edpuganti <aniedpuganti@gmail.com> ignores existing primary index Signed-off-by: Amit Singh <singhamitch@outlook.com> minor refactor Signed-off-by: Amit Singh <singhamitch@outlook.com> minor refactor Signed-off-by: Anirudh Edpuganti <aniedpuganti@gmail.com> * refactors logs and errors Signed-off-by: Amit Singh <singhamitch@outlook.com> * handles returned errors Signed-off-by: Amit Singh <amisingh@guidewire.com> --------- Signed-off-by: Anirudh Edpuganti <aniedpuganti@gmail.com> Signed-off-by: Amit Singh <singhamitch@outlook.com> Signed-off-by: Amit Singh <amisingh@guidewire.com> Co-authored-by: Anirudh Edpuganti <aniedpuganti@gmail.com> Co-authored-by: Amit Singh <amisingh@guidewire.com>
…#1750) * adds helper function to check for an arango collection index Signed-off-by: Anirudh Edpuganti <aedpuganti@guidewire.com> adds index struct to hold index data Signed-off-by: Amit Singh <singhamitch@outlook.com> adds func that returns full collection index mapping Signed-off-by: Amit Singh <singhamitch@outlook.com> adds logic to conditionally create collectionn indexes Signed-off-by: Amit Singh <amisingh@guidewire.com> removes todo Signed-off-by: Amit Singh <amisingh@guidewire.com> checks for missing vertex collection and creates them Signed-off-by: Anirudh Edpuganti <aniedpuganti@gmail.com> ignores existing primary index Signed-off-by: Amit Singh <singhamitch@outlook.com> minor refactor Signed-off-by: Amit Singh <singhamitch@outlook.com> minor refactor Signed-off-by: Anirudh Edpuganti <aniedpuganti@gmail.com> * refactors logs and errors Signed-off-by: Amit Singh <singhamitch@outlook.com> * handles returned errors Signed-off-by: Amit Singh <amisingh@guidewire.com> --------- Signed-off-by: Anirudh Edpuganti <aniedpuganti@gmail.com> Signed-off-by: Amit Singh <singhamitch@outlook.com> Signed-off-by: Amit Singh <amisingh@guidewire.com> Co-authored-by: Anirudh Edpuganti <aniedpuganti@gmail.com> Co-authored-by: Amit Singh <amisingh@guidewire.com>
Description of the PR
Currently when
guac
graph exists in arango backend, creation of collection indexes is skipped, this leads to missing/redundant indexes in the database after upgrades. This PR adds the logic to re-index collections if theguac
graph exists. The PR includes following changes:Fixes #1722
PR Checklist
-s
flag togit commit
.make generate
has been runmake generate
has been runcollectsub
protobuf has been changed,make proto
has been run