Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
B
brpc
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
brpc
Commits
be024bfb
Commit
be024bfb
authored
Jul 26, 2018
by
TousakaRin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change flag name from Controller::FLAGS_ADDED_CONCURRENCY to FLAGS_CONCURRENCY_LIMITER_REQUESTED
parent
c10ea28e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
controller.h
src/brpc/controller.h
+2
-2
server_private_accessor.h
src/brpc/details/server_private_accessor.h
+2
-2
No files found.
src/brpc/controller.h
View file @
be024bfb
...
...
@@ -115,8 +115,8 @@ friend void policy::ProcessThriftRequest(InputMessageBase*);
// << Flags >>
static
const
uint32_t
FLAGS_IGNORE_EOVERCROWDED
=
1
;
static
const
uint32_t
FLAGS_SECURITY_MODE
=
(
1
<<
1
);
//
Incremented Server._concurrency
static
const
uint32_t
FLAGS_
ADDED_CONCURRENCY
=
(
1
<<
2
);
//
Called Server._cl->OnRequested()
static
const
uint32_t
FLAGS_
CONCURRENCY_LIMITER_REQUESTED
=
(
1
<<
2
);
static
const
uint32_t
FLAGS_READ_PROGRESSIVELY
=
(
1
<<
3
);
static
const
uint32_t
FLAGS_PROGRESSIVE_READER
=
(
1
<<
4
);
static
const
uint32_t
FLAGS_BACKUP_REQUEST
=
(
1
<<
5
);
...
...
src/brpc/details/server_private_accessor.h
View file @
be024bfb
...
...
@@ -41,14 +41,14 @@ public:
// Returns true if the `max_concurrency' limit is not reached.
bool
AddConcurrency
(
Controller
*
c
)
{
if
(
NULL
!=
_server
->
_cl
)
{
c
->
add_flag
(
Controller
::
FLAGS_
ADDED_CONCURRENCY
);
c
->
add_flag
(
Controller
::
FLAGS_
CONCURRENCY_LIMITER_REQUESTED
);
return
_server
->
_cl
->
OnRequested
();
}
return
true
;
}
void
RemoveConcurrency
(
const
Controller
*
c
)
{
if
(
c
->
has_flag
(
Controller
::
FLAGS_
ADDED_CONCURRENCY
)){
if
(
c
->
has_flag
(
Controller
::
FLAGS_
CONCURRENCY_LIMITER_REQUESTED
)){
CHECK
(
_server
->
_cl
!=
NULL
);
_server
->
_cl
->
OnResponded
(
c
->
ErrorCode
(),
c
->
latency_us
());
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment