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
778e15ed
Commit
778e15ed
authored
Nov 09, 2017
by
gejun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Pass full options to the _schan inside DynamicPartitionChannel
parent
a79eeb57
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
1 addition
and
5 deletions
+1
-5
client.cpp
example/dynamic_partition_echo_c++/client.cpp
+0
-1
client.cpp
example/partition_echo_c++/client.cpp
+0
-1
partition_channel.cpp
src/brpc/partition_channel.cpp
+1
-3
No files found.
example/dynamic_partition_echo_c++/client.cpp
View file @
778e15ed
...
@@ -82,7 +82,6 @@ static void* sender(void* arg) {
...
@@ -82,7 +82,6 @@ static void* sender(void* arg) {
}
else
{
}
else
{
CHECK
(
brpc
::
IsAskedToQuit
()
||
!
FLAGS_dont_fail
)
CHECK
(
brpc
::
IsAskedToQuit
()
||
!
FLAGS_dont_fail
)
<<
"error="
<<
cntl
.
ErrorText
()
<<
" latency="
<<
cntl
.
latency_us
();
<<
"error="
<<
cntl
.
ErrorText
()
<<
" latency="
<<
cntl
.
latency_us
();
CHECK_LT
(
cntl
.
latency_us
(),
5000
);
// We can't connect to the server, sleep a while. Notice that this
// We can't connect to the server, sleep a while. Notice that this
// is a specific sleeping to prevent this thread from spinning too
// is a specific sleeping to prevent this thread from spinning too
// fast. You should continue the business logic in a production
// fast. You should continue the business logic in a production
...
...
example/partition_echo_c++/client.cpp
View file @
778e15ed
...
@@ -83,7 +83,6 @@ static void* sender(void* arg) {
...
@@ -83,7 +83,6 @@ static void* sender(void* arg) {
}
else
{
}
else
{
CHECK
(
brpc
::
IsAskedToQuit
()
||
!
FLAGS_dont_fail
)
CHECK
(
brpc
::
IsAskedToQuit
()
||
!
FLAGS_dont_fail
)
<<
"error="
<<
cntl
.
ErrorText
()
<<
" latency="
<<
cntl
.
latency_us
();
<<
"error="
<<
cntl
.
ErrorText
()
<<
" latency="
<<
cntl
.
latency_us
();
CHECK_LT
(
cntl
.
latency_us
(),
5000
);
// We can't connect to the server, sleep a while. Notice that this
// We can't connect to the server, sleep a while. Notice that this
// is a specific sleeping to prevent this thread from spinning too
// is a specific sleeping to prevent this thread from spinning too
// fast. You should continue the business logic in a production
// fast. You should continue the business logic in a production
...
...
src/brpc/partition_channel.cpp
View file @
778e15ed
...
@@ -457,9 +457,7 @@ int DynamicPartitionChannel::Init(
...
@@ -457,9 +457,7 @@ int DynamicPartitionChannel::Init(
LOG
(
ERROR
)
<<
"Fail to get NamingServiceThread"
;
LOG
(
ERROR
)
<<
"Fail to get NamingServiceThread"
;
return
-
1
;
return
-
1
;
}
}
ChannelOptions
schan_options
;
if
(
_schan
.
Init
(
"_dynpart"
,
options_in
)
!=
0
)
{
schan_options
.
succeed_without_server
=
ns_opt
.
succeed_without_server
;
if
(
_schan
.
Init
(
"_dynpart"
,
&
schan_options
)
!=
0
)
{
LOG
(
ERROR
)
<<
"Fail to init _schan"
;
LOG
(
ERROR
)
<<
"Fail to init _schan"
;
return
-
1
;
return
-
1
;
}
}
...
...
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