Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
spark
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
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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
cs525-sp18-g07
spark
Commits
1f5a7e0e
Commit
1f5a7e0e
authored
12 years ago
by
mbautin
Browse files
Options
Downloads
Patches
Plain Diff
SPARK-624: make the default local IP customizable
parent
c23a74df
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
core/src/main/scala/spark/Utils.scala
+7
-1
7 additions, 1 deletion
core/src/main/scala/spark/Utils.scala
with
7 additions
and
1 deletion
core/src/main/scala/spark/Utils.scala
+
7
−
1
View file @
1f5a7e0e
...
@@ -199,7 +199,13 @@ private object Utils extends Logging {
...
@@ -199,7 +199,13 @@ private object Utils extends Logging {
/**
/**
* Get the local host's IP address in dotted-quad format (e.g. 1.2.3.4).
* Get the local host's IP address in dotted-quad format (e.g. 1.2.3.4).
*/
*/
def
localIpAddress
()
:
String
=
InetAddress
.
getLocalHost
.
getHostAddress
def
localIpAddress
()
:
String
=
{
val
defaultIpOverride
=
System
.
getenv
(
"SPARK_DEFAULT_LOCAL_IP"
)
if
(
defaultIpOverride
!=
null
)
defaultIpOverride
else
InetAddress
.
getLocalHost
.
getHostAddress
}
private
var
customHostname
:
Option
[
String
]
=
None
private
var
customHostname
:
Option
[
String
]
=
None
...
...
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