Code example for AtomicReference

Methods: set

0
    ); 
    Assert.assertFalse(provisionedSomething);
    EasyMock.verify(autoScalingStrategy);
 
    // Increase minVersion 
    workerSetupData.set(new WorkerSetupData("1", 0, 2, null, null, null));
 
    // Provision two new workers 
    EasyMock.reset(autoScalingStrategy);
    EasyMock.expect(autoScalingStrategy.ipToIdLookup(EasyMock.<List<String>>anyObject()))
            .andReturn(Lists.<String>newArrayList("ip"));
    EasyMock.expect(autoScalingStrategy.provision()).andReturn(
        new AutoScalingData(Lists.<String>newArrayList("h3"))
    ); 
    EasyMock.expect(autoScalingStrategy.provision()).andReturn(
        new AutoScalingData(Lists.<String>newArrayList("h4"))
    ); 
    EasyMock.replay(autoScalingStrategy);
    provisionedSomething = simpleResourceManagementStrategy.doProvision(
        Arrays.<RemoteTaskRunnerWorkItem>asList(),
        Arrays.<ZkWorker>asList(