Skip to content

Commit

Permalink
[SPARK-2140] Removing calculateAMMemory functions since they are no l…
Browse files Browse the repository at this point in the history
…onger needed.
  • Loading branch information
Chris Cope committed Sep 4, 2014
1 parent 52b4e45 commit 5ad89da
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,6 @@ class Client(clientArgs: ClientArguments, hadoopConf: Configuration, spConf: Spa
appContext
}

def calculateAMMemory(newApp: GetNewApplicationResponse): Int = {
args.amMemory
}

def setupSecurityToken(amContainer: ContainerLaunchContext) = {
// Setup security tokens.
val dob = new DataOutputBuffer()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -300,8 +300,6 @@ trait ClientBase extends Logging {
retval.toString
}

def calculateAMMemory(newApp: GetNewApplicationResponse): Int

def setupSecurityToken(amContainer: ContainerLaunchContext)

def createContainerLaunchContext(
Expand Down Expand Up @@ -346,7 +344,7 @@ trait ClientBase extends Logging {
}
amContainer.setEnvironment(env)

val amMemory = calculateAMMemory(newApp)
val amMemory = args.amMemory

val javaOpts = ListBuffer[String]()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -238,9 +238,6 @@ class ClientBaseSuite extends FunSuite with Matchers {
val sparkConf: SparkConf,
val yarnConf: YarnConfiguration) extends ClientBase {

override def calculateAMMemory(newApp: GetNewApplicationResponse): Int =
throw new UnsupportedOperationException()

override def setupSecurityToken(amContainer: ContainerLaunchContext): Unit =
throw new UnsupportedOperationException()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,6 @@ class Client(clientArgs: ClientArguments, hadoopConf: Configuration, spConf: Spa
clusterMetrics.getNumNodeManagers)
}

def calculateAMMemory(newApp: GetNewApplicationResponse) :Int = {
args.amMemory
}

def setupSecurityToken(amContainer: ContainerLaunchContext) = {
// Setup security tokens.
val dob = new DataOutputBuffer()
Expand Down

0 comments on commit 5ad89da

Please sign in to comment.