-
Notifications
You must be signed in to change notification settings - Fork 447
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
feat(flex): Support using property of string type as primary key for vertex #3296
Conversation
cec8469
to
94578b1
Compare
label_t src_label, dst_label, edge_label; | ||
arc >> src_label; | ||
arc.GetBytes(sizeof(oid_t)); | ||
arc >> temp; | ||
// arc.GetBytes(sizeof(PropertyType) + sizeof(int64_t)); |
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.
These comments can be removed?
@@ -22,7 +22,7 @@ static uint32_t get_vertex_vid(const gs::ReadTransaction& txn, uint8_t label, | |||
uint32_t vid = std::numeric_limits<uint32_t>::max(); | |||
auto vit = txn.GetVertexIterator(label); | |||
for (; vit.IsValid(); vit.Next()) { | |||
if (vit.GetId() == id) { | |||
if (vit.GetId().AsInt64() == id) { |
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.
If the result of vit.GetId()
must be int64()
, do the check first?
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.
Checked inside the AsXX() function
@@ -22,7 +22,7 @@ static uint32_t get_vertex_vid(const gs::ReadTransaction& txn, uint8_t label, | |||
uint32_t vid = std::numeric_limits<uint32_t>::max(); |
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.
using oid_t = int64_t;
declared in flex/storages/rt_mutable_graph/types.h
should be removed, and we shall ensure can remove all usage of oid_t is this PR?
…into string_support
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
What do these changes do?
oid support string_view
Related issue number
Fixes