Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[COR-56] Unify VertexRef#22165

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
markuspf wants to merge7 commits intodevel
base:devel
Choose a base branch
Loading
fromchore/unify-vertex-ref
Open

Conversation

@markuspf
Copy link
Contributor

@markuspfmarkuspf commentedDec 5, 2025
edited by cursorbot
Loading

Scope & Purpose

Use the same definition ofVertexRef throughout;

Before this patch, there were various places in the codebase which usedusing VertexRef = HashedStringRef, as well asSteps in the traverser code wrapping thisHashedStringRef into a helper class, which is identical for every Step type.

This PR introduces a classVertexRef which replaces all these uses consistently (and is currently only a wrapper aroundHashedStringRef

Requires Enterprise PR:https://github.com/arangodb/enterprise/pull/1563


Note

Introduces a unifiedVertexRef wrapper (overHashedStringRef) and replaces ad-hoc vertex ID types/usages across graph components, updating APIs, data structures, and tests.

  • Types:
    • Addgraph::VertexRef (Graph/Types/VertexRef.{h,cpp}) andVertexSet (Graph/Types/VertexSet.h); migrateForbiddenVertices.h to use them.
  • APIs and Call Sites:
    • ReplaceHashedStringRef vertex IDs withVertexRef in public methods (e.g.,reset,startVertex,addVertexToBuilder) across executors (TraversalExecutor,ShortestPathExecutor,EnumeratePathsExecutor).
  • Enumerators:
    • Update One-/Two-Sided, Weighted (Shortest/KShortest), and Yen enumerators to consume/produceVertexRef; switch internal maps/sets to key byVertexRef.
  • Providers/Steps:
    • AdjustSingleServerProvider,ClusterProvider,ProviderTracer, and step types to store/returnVertexRef and propagate through expansion/builders.
  • Path Management:
    • ModifyPathResult andSingleProviderPathResult to store vertices asVertexRef; update memory accounting and VPack emission;PathValidator* now usesVertexRef for uniqueness/forbidden checks.
  • Tests:
    • Update all graph tests and mock provider to construct and compare vertices viaVertexRef.

Written byCursor Bugbot for commit2cdb2fe. This will update automatically on new commits. Configurehere.

Copy link

@cursorcursorbot left a comment

Choose a reason for hiding this comment

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

This PR is being reviewed by Cursor Bugbot

Details

Your team is on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle for each member of your team.

To receive Bugbot reviews on all of your PRs, visit theCursor dashboard to activate Pro and start your 14-day free trial.

// need a mechanism here as well to distinguish between (non)required
// parameters.
callback(Step{to, edge, previous, fetchedType, step.getDepth() +1,
callback(Step{VertexRef{to}, VertexRef{edge}, previous, fetchedType,
Copy link

Choose a reason for hiding this comment

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

Bug: Edge ID incorrectly wrapped in VertexRef type

Theedge variable (an edge ID of typeEdgeType/HashedStringRef) is incorrectly wrapped inVertexRef{edge}. TheClusterProviderStep constructor expectsEdgeType for the second parameter, notVertexRef. While this currently works due to the implicit conversion operator inVertexRef, it semantically treats an edge ID as a vertex reference. Onlyto (the vertex ID) should be wrapped inVertexRef;edge should be passed directly.

Fix in Cursor Fix in Web

jvolmer reacted with thumbs up emoji
Copy link
Contributor

@jvolmerjvolmer left a comment

Choose a reason for hiding this comment

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

Two small include improvements and the cursor-comment above looks legitimate. Otherwise, LGTM

Comment on lines 52 to 54
using VertexSet = arangodb::containers::HashSet<VertexRef, std::hash<VertexRef>,
std::equal_to<VertexRef>>;

Copy link
Contributor

Choose a reason for hiding this comment

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

should probably be exchanged with#include "Graph/Types/VertexSet.h"

Comment on lines 53 to 55
using VertexSet = arangodb::containers::HashSet<VertexRef, std::hash<VertexRef>,
std::equal_to<VertexRef>>;

Copy link
Contributor

Choose a reason for hiding this comment

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

same here

@markuspfmarkuspf changed the title[COR] Unify VertexRef[COR-56] Unify VertexRefDec 11, 2025
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@cursorcursor[bot]cursor[bot] left review comments

@jvolmerjvolmerjvolmer approved these changes

@mpoetermpoeterAwaiting requested review from mpoeter

Assignees

No one assigned

Labels

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

3 participants

@markuspf@jvolmer

[8]ページ先頭

©2009-2025 Movatter.jp