Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
9b1543c2
Commit
9b1543c2
authored
May 10, 2019
by
Elad
Committed by
Anton Evangelatov
May 10, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
swarm/network: update syncer metrics
parent
297fa185
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
4 deletions
+3
-4
syncer.go
swarm/network/stream/syncer.go
+3
-4
No files found.
swarm/network/stream/syncer.go
View file @
9b1543c2
...
...
@@ -111,13 +111,13 @@ func (s *SwarmSyncerServer) SetNextBatch(from, to uint64) ([]byte, uint64, uint6
timerC
<-
chan
time
.
Time
)
defer
func
()
{
metrics
.
GetOrRegisterResettingTimer
(
"syncer.set-next-batch.total-time"
,
nil
)
.
UpdateSince
(
batchS
tart
)
defer
func
(
start
time
.
Time
)
{
metrics
.
GetOrRegisterResettingTimer
(
"syncer.set-next-batch.total-time"
,
nil
)
.
UpdateSince
(
s
tart
)
metrics
.
GetOrRegisterCounter
(
"syncer.set-next-batch.batch-size"
,
nil
)
.
Inc
(
int64
(
batchSize
))
if
timer
!=
nil
{
timer
.
Stop
()
}
}()
}(
batchStart
)
for
iterate
:=
true
;
iterate
;
{
select
{
...
...
@@ -167,7 +167,6 @@ func (s *SwarmSyncerServer) SetNextBatch(from, to uint64) ([]byte, uint64, uint6
log
.
Debug
(
"syncer pull subscription timer expired"
,
"correlateId"
,
s
.
correlateId
,
"batchSize"
,
batchSize
,
"batchStartID"
,
batchStartID
,
"batchEndID"
,
batchEndID
)
case
<-
s
.
quit
:
iterate
=
false
metrics
.
GetOrRegisterCounter
(
"syncer.set-next-batch.quit-sig"
,
nil
)
.
Inc
(
1
)
log
.
Debug
(
"syncer pull subscription - quit received"
,
"correlateId"
,
s
.
correlateId
,
"batchSize"
,
batchSize
,
"batchStartID"
,
batchStartID
,
"batchEndID"
,
batchEndID
)
}
}
...
...
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