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
977892a3
Commit
977892a3
authored
Sep 29, 2018
by
gejun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix removed ControllerPrivateAccessor.connection_type()
parent
48dae6ce
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
7 additions
and
8 deletions
+7
-8
esp_protocol.cpp
src/brpc/policy/esp_protocol.cpp
+1
-1
nova_pbrpc_protocol.cpp
src/brpc/policy/nova_pbrpc_protocol.cpp
+1
-1
nshead_mcpack_protocol.cpp
src/brpc/policy/nshead_mcpack_protocol.cpp
+1
-1
nshead_protocol.cpp
src/brpc/policy/nshead_protocol.cpp
+1
-1
public_pbrpc_protocol.cpp
src/brpc/policy/public_pbrpc_protocol.cpp
+1
-2
thrift_protocol.cpp
src/brpc/policy/thrift_protocol.cpp
+1
-1
ubrpc2pb_protocol.cpp
src/brpc/policy/ubrpc2pb_protocol.cpp
+1
-1
No files found.
src/brpc/policy/esp_protocol.cpp
View file @
977892a3
...
...
@@ -92,7 +92,7 @@ void PackEspRequest(butil::IOBuf* packet_buf,
const
Authenticator
*
auth
)
{
ControllerPrivateAccessor
accessor
(
cntl
);
if
(
accessor
.
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
if
(
cntl
->
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
return
cntl
->
SetFailed
(
EINVAL
,
"esp protocol can't work with CONNECTION_TYPE_SINGLE"
);
}
...
...
src/brpc/policy/nova_pbrpc_protocol.cpp
View file @
977892a3
...
...
@@ -169,7 +169,7 @@ void PackNovaRequest(butil::IOBuf* buf,
const
butil
::
IOBuf
&
request
,
const
Authenticator
*
/*not supported*/
)
{
ControllerPrivateAccessor
accessor
(
controller
);
if
(
accessor
.
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
if
(
controller
->
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
return
controller
->
SetFailed
(
EINVAL
,
"nova_pbrpc can't work with CONNECTION_TYPE_SINGLE"
);
}
...
...
src/brpc/policy/nshead_mcpack_protocol.cpp
View file @
977892a3
...
...
@@ -157,7 +157,7 @@ void PackNsheadMcpackRequest(butil::IOBuf* buf,
const
butil
::
IOBuf
&
request
,
const
Authenticator
*
/*not supported*/
)
{
ControllerPrivateAccessor
accessor
(
controller
);
if
(
accessor
.
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
if
(
controller
->
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
return
controller
->
SetFailed
(
EINVAL
,
"nshead_mcpack can't work with CONNECTION_TYPE_SINGLE"
);
}
...
...
src/brpc/policy/nshead_protocol.cpp
View file @
977892a3
...
...
@@ -399,7 +399,7 @@ void PackNsheadRequest(
const
butil
::
IOBuf
&
request
,
const
Authenticator
*
)
{
ControllerPrivateAccessor
accessor
(
cntl
);
if
(
accessor
.
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
if
(
cntl
->
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
return
cntl
->
SetFailed
(
EINVAL
,
"nshead protocol can't work with CONNECTION_TYPE_SINGLE"
);
}
...
...
src/brpc/policy/public_pbrpc_protocol.cpp
View file @
977892a3
...
...
@@ -236,8 +236,7 @@ void PackPublicPbrpcRequest(butil::IOBuf* buf,
head
->
set_from_host
(
butil
::
ip2str
(
butil
::
my_ip
()).
c_str
());
head
->
set_content_type
(
CONTENT_TYPE
);
bool
short_connection
=
(
ControllerPrivateAccessor
(
controller
)
.
connection_type
()
==
CONNECTION_TYPE_SHORT
);
bool
short_connection
=
(
controller
->
connection_type
()
==
CONNECTION_TYPE_SHORT
);
head
->
set_connection
(
!
short_connection
);
head
->
set_charset
(
CHARSET
);
char
time_buf
[
128
];
...
...
src/brpc/policy/thrift_protocol.cpp
View file @
977892a3
...
...
@@ -726,7 +726,7 @@ void PackThriftRequest(
const
butil
::
IOBuf
&
request
,
const
Authenticator
*
)
{
ControllerPrivateAccessor
accessor
(
cntl
);
if
(
accessor
.
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
if
(
cntl
->
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
return
cntl
->
SetFailed
(
EINVAL
,
"thrift protocol can't work with CONNECTION_TYPE_SINGLE"
);
}
...
...
src/brpc/policy/ubrpc2pb_protocol.cpp
View file @
977892a3
...
...
@@ -541,7 +541,7 @@ void PackUbrpcRequest(butil::IOBuf* buf,
const
butil
::
IOBuf
&
request
,
const
Authenticator
*
/*not supported*/
)
{
ControllerPrivateAccessor
accessor
(
controller
);
if
(
accessor
.
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
if
(
controller
->
connection_type
()
==
CONNECTION_TYPE_SINGLE
)
{
return
controller
->
SetFailed
(
EINVAL
,
"ubrpc protocol can't work with CONNECTION_TYPE_SINGLE"
);
}
...
...
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