Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
LiFiBenchMarkingNetwork
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Savage
LiFiGroup
LiFiBenchMarkingNetwork
Commits
d6e8ffdb
Commit
d6e8ffdb
authored
6 years ago
by
Brutzman, Don
Browse files
Options
Downloads
Patches
Plain Diff
better name SERVER_TIMEOUT_MSEC
parent
fba4e7cd
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/edu/nps/moves/lifi/LiFiBenchmark.java
+3
-3
3 additions, 3 deletions
src/edu/nps/moves/lifi/LiFiBenchmark.java
with
3 additions
and
3 deletions
src/edu/nps/moves/lifi/LiFiBenchmark.java
+
3
−
3
View file @
d6e8ffdb
...
...
@@ -45,7 +45,7 @@ public class LiFiBenchmark
public
static
final
int
DEFAULT_READ_LIMIT
=
1500000
*
1024
;
public
static
final
boolean
DEFAULT_SERVER_FLAG
=
false
;
public
static
final
int
DEFAULT_DISCARD_REPS
=
0
;
public
static
final
int
TEN_SECONDS
=
30000
;
// ms
public
static
final
int
SERVER_TIMEOUT_MSEC
=
30000
;
// ms
private
String
targetIp
=
DEFAULT_IP
;
private
int
targetPort
=
DEFAULT_PORT
;
...
...
@@ -149,7 +149,7 @@ public class LiFiBenchmark
try
{
ssock
=
new
ServerSocket
(
targetPort
);
ssock
.
setSoTimeout
(
TEN_SECONDS
);
ssock
.
setSoTimeout
(
SERVER_TIMEOUT_MSEC
);
System
.
out
.
println
(
"Serving from "
+
Inet4Address
.
getLocalHost
().
getHostAddress
());
System
.
out
.
println
(
"Waiting on port "
+
targetPort
);
...
...
@@ -161,7 +161,7 @@ public class LiFiBenchmark
catch
(
IOException
ex
)
{
String
msg
=
ex
.
getMessage
();
if
(
msg
.
contains
(
"Accept timed out"
))
System
.
out
.
println
(
msg
+
" after "
+
TEN_SECONDS
/
1000
+
" seconds"
);
System
.
out
.
println
(
msg
+
" after "
+
SERVER_TIMEOUT_MSEC
/
1000
+
" seconds"
);
else
{
System
.
err
.
println
(
"Exception waiting for connections: "
+
msg
);
System
.
exit
(-
1
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment