-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
profiling storage detail #2754
Merged
bright-starry-sky
merged 9 commits into
vesoft-inc:master
from
cangfengzhs:profiling_storage_detail
Sep 14, 2021
Merged
profiling storage detail #2754
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
f7ca01d
profiling storage detail
cangfengzhs 447c213
Merge remote-tracking branch 'vesoft/master' into profiling_storage_d…
cangfengzhs 59a3a70
address critical27's comment
cangfengzhs c110c96
Merge branch 'master' into profiling_storage_detail
cangfengzhs 4f9f1be
Merge branch 'master' into profiling_storage_detail
cangfengzhs c81e269
Merge branch 'master' into profiling_storage_detail
cangfengzhs 86d128c
Merge branch 'master' into profiling_storage_detail
cangfengzhs 3ff4326
Merge branch 'master' into profiling_storage_detail
critical27 ac5963e
Merge branch 'master' into profiling_storage_detail
critical27 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -52,9 +52,12 @@ class EdgeNode : public IterateNode<T> { | |
schemas_ = &(schemaIter->second); | ||
ttl_ = QueryUtils::getEdgeTTLInfo(edgeContext_, std::abs(edgeType_)); | ||
edgeName_ = edgeContext_->edgeNames_[edgeType_]; | ||
IterateNode<T>::name_ = "EdgeNode"; | ||
} | ||
|
||
EdgeNode(RuntimeContext* context, EdgeContext* ctx) : context_(context), edgeContext_(ctx) {} | ||
EdgeNode(RuntimeContext* context, EdgeContext* ctx) : context_(context), edgeContext_(ctx) { | ||
IterateNode<T>::name_ = "EdgeNode"; | ||
} | ||
|
||
RuntimeContext* context_; | ||
EdgeContext* edgeContext_; | ||
|
@@ -71,15 +74,17 @@ class EdgeNode : public IterateNode<T> { | |
// FetchEdgeNode is used to fetch a single edge | ||
class FetchEdgeNode final : public EdgeNode<cpp2::EdgeKey> { | ||
public: | ||
using RelNode::execute; | ||
using RelNode::doExecute; | ||
|
||
FetchEdgeNode(RuntimeContext* context, | ||
EdgeContext* edgeContext, | ||
EdgeType edgeType, | ||
const std::vector<PropContext>* props, | ||
StorageExpressionContext* expCtx = nullptr, | ||
Expression* exp = nullptr) | ||
: EdgeNode(context, edgeContext, edgeType, props, expCtx, exp) {} | ||
: EdgeNode(context, edgeContext, edgeType, props, expCtx, exp) { | ||
name_ = "FetchEdgeNode"; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ditto |
||
} | ||
|
||
bool valid() const override { return valid_; } | ||
|
||
|
@@ -91,9 +96,9 @@ class FetchEdgeNode final : public EdgeNode<cpp2::EdgeKey> { | |
|
||
RowReader* reader() const override { return reader_.get(); } | ||
|
||
nebula::cpp2::ErrorCode execute(PartitionID partId, const cpp2::EdgeKey& edgeKey) override { | ||
nebula::cpp2::ErrorCode doExecute(PartitionID partId, const cpp2::EdgeKey& edgeKey) override { | ||
valid_ = false; | ||
auto ret = RelNode::execute(partId, edgeKey); | ||
auto ret = RelNode::doExecute(partId, edgeKey); | ||
if (ret != nebula::cpp2::ErrorCode::SUCCEEDED) { | ||
return ret; | ||
} | ||
|
@@ -143,14 +148,16 @@ class FetchEdgeNode final : public EdgeNode<cpp2::EdgeKey> { | |
// srcId | ||
class SingleEdgeNode final : public EdgeNode<VertexID> { | ||
public: | ||
using RelNode::execute; | ||
using RelNode::doExecute; | ||
SingleEdgeNode(RuntimeContext* context, | ||
EdgeContext* edgeContext, | ||
EdgeType edgeType, | ||
const std::vector<PropContext>* props, | ||
StorageExpressionContext* expCtx = nullptr, | ||
Expression* exp = nullptr) | ||
: EdgeNode(context, edgeContext, edgeType, props, expCtx, exp) {} | ||
: EdgeNode(context, edgeContext, edgeType, props, expCtx, exp) { | ||
name_ = "SingleEdgeNode"; | ||
} | ||
|
||
SingleEdgeIterator* iter() { return iter_.get(); } | ||
|
||
|
@@ -164,8 +171,8 @@ class SingleEdgeNode final : public EdgeNode<VertexID> { | |
|
||
RowReader* reader() const override { return iter_->reader(); } | ||
|
||
nebula::cpp2::ErrorCode execute(PartitionID partId, const VertexID& vId) override { | ||
auto ret = RelNode::execute(partId, vId); | ||
nebula::cpp2::ErrorCode doExecute(PartitionID partId, const VertexID& vId) override { | ||
auto ret = RelNode::doExecute(partId, vId); | ||
if (ret != nebula::cpp2::ErrorCode::SUCCEEDED) { | ||
return ret; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
@cangfengzhs
I really don't recommend this way to initialize the fields of the base class. Please provide the constructor in the base class to do this, such as: