Skip to content

Commit

Permalink
[SMALLFIX] Replace misleading double types with longs
Browse files Browse the repository at this point in the history
  • Loading branch information
aaudiber committed Oct 31, 2015
1 parent 2d22948 commit acb57f2
Showing 1 changed file with 5 additions and 4 deletions.
Expand Up @@ -96,10 +96,11 @@ public void reregistered(SchedulerDriver driver, Protos.MasterInfo masterInfo) {

@Override
public void resourceOffers(SchedulerDriver driver, List<Protos.Offer> offers) {
double masterCpu = sConf.getInt(Constants.INTEGRATION_MASTER_RESOURCE_CPU);
double masterMem = sConf.getBytes(Constants.INTEGRATION_MASTER_RESOURCE_MEM) / Constants.MB;
double workerCpu = sConf.getInt(Constants.INTEGRATION_WORKER_RESOURCE_CPU);
double workerMem = sConf.getBytes(Constants.INTEGRATION_WORKER_RESOURCE_MEM) / Constants.MB;
// TODO(andrew): Should these be doubles or longs?
long masterCpu = sConf.getInt(Constants.INTEGRATION_MASTER_RESOURCE_CPU);
long masterMem = sConf.getBytes(Constants.INTEGRATION_MASTER_RESOURCE_MEM) / Constants.MB;
long workerCpu = sConf.getInt(Constants.INTEGRATION_WORKER_RESOURCE_CPU);
long workerMem = sConf.getBytes(Constants.INTEGRATION_WORKER_RESOURCE_MEM) / Constants.MB;

for (Protos.Offer offer : offers) {
Protos.Offer.Operation.Launch.Builder launch = Protos.Offer.Operation.Launch.newBuilder();
Expand Down

0 comments on commit acb57f2

Please sign in to comment.