better logs

This commit is contained in:
Fangjin Yang 2013-02-01 17:16:24 -08:00
parent 9e88197845
commit d9f2e68f7f
2 changed files with 5 additions and 1 deletions

View File

@ -563,7 +563,7 @@ public class RemoteTaskRunner implements TaskRunner
);
if (workerQueue.isEmpty()) {
log.info("Worker nodes do not have capacity to run any more tasks!");
log.info("Worker nodes %s do not have capacity to run any more tasks!", zkWorkers.values());
if (currentlyProvisioning.isEmpty()) {
AutoScalingData provisioned = strategy.provision();

View File

@ -130,6 +130,10 @@ public class EC2AutoScalingStrategy implements ScalingStrategy<Instance>
@Override
public AutoScalingData<Instance> terminate(List<String> ids)
{
if (ids.isEmpty()) {
return new AutoScalingData<Instance>(Lists.<String>newArrayList(), Lists.<Instance>newArrayList());
}
DescribeInstancesResult result = amazonEC2Client.describeInstances(
new DescribeInstancesRequest()
.withFilters(