Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
2
210360228
Manage
Activity
Members
Labels
Plan
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Summer2021
210360228
Commits
0766f2b2
Unverified
Commit
0766f2b2
authored
4 years ago
by
cpw
Committed by
GitHub
4 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Return partial succeeded. (#851)
parent
2419f28b
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/context/QueryContext.h
+5
-0
5 additions, 0 deletions
src/context/QueryContext.h
src/executor/StorageAccessExecutor.h
+3
-1
3 additions, 1 deletion
src/executor/StorageAccessExecutor.h
src/service/GraphService.cpp
+2
-0
2 additions, 0 deletions
src/service/GraphService.cpp
with
10 additions
and
1 deletion
src/context/QueryContext.h
+
5
−
0
View file @
0766f2b2
...
...
@@ -125,6 +125,11 @@ public:
return
symTable_
.
get
();
}
void
setPartialSuccess
()
{
DCHECK
(
rctx_
!=
nullptr
);
rctx_
->
resp
().
errorCode
=
ErrorCode
::
E_PARTIAL_SUCCEEDED
;
}
private
:
void
init
();
...
...
This diff is collapsed.
Click to expand it.
src/executor/StorageAccessExecutor.h
+
3
−
1
View file @
0766f2b2
...
...
@@ -7,8 +7,9 @@
#ifndef EXECUTOR_STORAGEACCESSEXECUTOR_H_
#define EXECUTOR_STORAGEACCESSEXECUTOR_H_
#include
"executor/Executor.h"
#include
"common/clients/storage/StorageClientBase.h"
#include
"context/QueryContext.h"
#include
"executor/Executor.h"
namespace
nebula
{
namespace
graph
{
...
...
@@ -44,6 +45,7 @@ protected:
return
Status
::
Error
(
"Request to storage failed, without failedCodes."
);
}
// partial success is accepted
qctx
()
->
setPartialSuccess
();
return
Result
::
State
::
kPartialSuccess
;
}
return
Result
::
State
::
kSuccess
;
...
...
This diff is collapsed.
Click to expand it.
src/service/GraphService.cpp
+
2
−
0
View file @
0766f2b2
...
...
@@ -125,6 +125,8 @@ const char* GraphService::getErrorStr(ErrorCode result) {
return
"User not found"
;
case
ErrorCode
::
E_TOO_MANY_CONNECTIONS
:
return
"Too many connections"
;
case
ErrorCode
::
E_PARTIAL_SUCCEEDED
:
return
"Partial results"
;
}
/**********************
* Unknown error
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment