Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
G
getty
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wei.xuan
getty
Commits
957f65f6
Unverified
Commit
957f65f6
authored
Aug 13, 2020
by
watermelon
Committed by
GitHub
Aug 13, 2020
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #46 from aliiohs/exposeMaxWheelTimeSpan
Fix:ExposeMaxWheelTimeSpan
parents
fb33e078
f9c6e8b9
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
8 deletions
+9
-8
session.go
session.go
+9
-8
No files found.
session.go
View file @
957f65f6
...
@@ -45,7 +45,8 @@ const (
...
@@ -45,7 +45,8 @@ const (
pendingDuration
=
3e9
pendingDuration
=
3e9
defaultQLen
=
1024
defaultQLen
=
1024
maxIovecNum
=
10
maxIovecNum
=
10
maxWheelTimeSpan
=
900e9
// 900s, 15 minute
//MaxWheelTimeSpan 900s, 15 minute
MaxWheelTimeSpan
=
900e9
defaultSessionName
=
"session"
defaultSessionName
=
"session"
defaultTCPSessionName
=
"tcp-session"
defaultTCPSessionName
=
"tcp-session"
...
@@ -65,7 +66,7 @@ var (
...
@@ -65,7 +66,7 @@ var (
func
init
()
{
func
init
()
{
span
:=
100e6
// 100ms
span
:=
100e6
// 100ms
buckets
:=
m
axWheelTimeSpan
/
span
buckets
:=
M
axWheelTimeSpan
/
span
wheel
=
gxtime
.
NewWheel
(
time
.
Duration
(
span
),
int
(
buckets
))
// wheel longest span is 15 minute
wheel
=
gxtime
.
NewWheel
(
time
.
Duration
(
span
),
int
(
buckets
))
// wheel longest span is 15 minute
}
}
...
...
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