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

fix insert edge #2862

Merged
merged 2 commits into from
Sep 22, 2021
Merged

fix insert edge #2862

merged 2 commits into from
Sep 22, 2021

Conversation

czpmango
Copy link
Contributor

@czpmango czpmango commented Sep 14, 2021

Fixes #2739

@czpmango czpmango added the ready-for-testing PR: ready for the CI test label Sep 14, 2021
Copy link
Contributor

@yixinglu yixinglu left a comment

Choose a reason for hiding this comment

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

Fix what problem? could you give some cases ?

@czpmango
Copy link
Contributor Author

Fix what problem? could you give some cases ?

In the case of multiple replicas, insert statements may cause inconsistent attribute values ​​between replicas.

create edge E(prop timestamp default timestamp())
insert edge E() values "1"->"2":()

@Shylock-Hg
Copy link
Contributor

Fix what problem? could you give some cases ?

In the case of multiple replicas, insert statements may cause inconsistent attribute values ​​between replicas.

create edge E(prop timestamp default timestamp())
insert edge E() values "1"->"2":()

Between partitions instead of replicas.

@czpmango
Copy link
Contributor Author

Fix what problem? could you give some cases ?

In the case of multiple replicas, insert statements may cause inconsistent attribute values ​​between replicas.

create edge E(prop timestamp default timestamp())
insert edge E() values "1"->"2":()

Between partitions instead of replicas.

You are right.

@Shylock-Hg Shylock-Hg added the type/bug Type: something is unexpected label Sep 15, 2021
@Shylock-Hg
Copy link
Contributor

Add case to compare properties of in/out edges

@Shylock-Hg
Copy link
Contributor

Close #2867

@kikimo
Copy link
Contributor

kikimo commented Sep 15, 2021

Close #2867
@Shylock-Hg

We are testing TOSS feature, not sure this is the same problem you are confronting.
If it's timestamp() mismatch, then #2867 is a whold different problem.

@Shylock-Hg
Copy link
Contributor

Close #2867
@Shylock-Hg

We are testing TOSS feature, not sure this is the same problem you are confronting.
If it's timestamp() mismatch, then #2867 is a whold different problem.

TOSS is another way could resolve this problem.

@kikimo
Copy link
Contributor

kikimo commented Sep 15, 2021

Close #2867
@Shylock-Hg

We are testing TOSS feature, not sure this is the same problem you are confronting.
If it's timestamp() mismatch, then #2867 is a whold different problem.

TOSS is another way could resolve this problem.

Sadly TOSS cannot fix too. The problem issue #2867 mentioning is the mismatch of int value of edge props without default. BTW @liuyu85cn has already did some fix for the default timestamp() value mismatch at the storage level.

@Shylock-Hg
Copy link
Contributor

Close #2867
@Shylock-Hg

We are testing TOSS feature, not sure this is the same problem you are confronting.
If it's timestamp() mismatch, then #2867 is a whold different problem.

TOSS is another way could resolve this problem.

Sadly TOSS cannot fix too. The problem issue #2867 mentioning is the mismatch of int value of edge props without default. BTW @liuyu85cn has already did some fix for the default timestamp() value mismatch at the storage level.

Could resolve the default value issue.

@czpmango
Copy link
Contributor Author

czpmango commented Sep 16, 2021

Close #2867
@Shylock-Hg

We are testing TOSS feature, not sure this is the same problem you are confronting.
If it's timestamp() mismatch, then #2867 is a whold different problem.

This pr and issue #2739 has nothing to do with toss, it is just to fix Default Value problem.

src/graph/validator/MutateValidator.cpp Outdated Show resolved Hide resolved
src/graph/validator/MutateValidator.cpp Outdated Show resolved Hide resolved
std::vector<Value> entirePropValues;
for (size_t j = 0; j < fieldNum; ++j) {
auto *field = schema_->field(j);
auto propName = entirePropNames_[j];
Copy link
Contributor

Choose a reason for hiding this comment

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

It seems that the entirePropNames_ is not necessary, why not use schema_->field(j)->name() here directly. And you needs not to save it as the field of MutateValidator

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Also used in InsertEdgesValidator::toPlan().

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-for-testing PR: ready for the CI test type/bug Type: something is unexpected
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The default value stored as an expression existed one problem.
5 participants