Buggy code:
public class GCEOperations { private static final Log log = LogFactory . getLog ( GCELoadBalancer . class ) ; private static final String PROJECT_NAME = GCEContext . getInstance ( ) . getProjectName ( ) ; private static final String PROJECT_ID = GCEContext . getInstance ( ) . getProjectID ( ) ; private static final String ZONE_NAME = GCEContext . getInstance ( ) . getZoneName ( ) ; private static final String REGION_NAME = GCEContext . getInstance ( ) . getRegionName ( ) ; private static final String KEY_FILE_PATH = GCEContext . getInstance ( ) . getKeyFilePath ( ) ; private static final String ACCOUNT_ID = GCEContext . getInstance ( ) . getGceAccountID ( ) ; private static final String HEALTH_CHECK_REQUEST_PATH = GCEContext . getInstance ( ) . getHealthCheckRequestPath ( ) ; private static final String HEALTH_CHECK_PORT = GCEContext . getInstance ( ) . getHealthCheckPort ( ) ; private static final String HEALTH_CHECK_TIME_OUT_SEC = GCEContext . getInstance ( ) . getHealthCheckTimeOutSec ( ) ; private static final String HEALTH_CHECK_UNHEALTHY_THRESHOLD = GCEContext . getInstance ( ) . getHealthCheckUnhealthyThreshold ( ) ; private static final String DATA_STORE_DIR = ".store//gce-extension" ; private static final String RUNNING_FILTER = "status<seq2seq4repair_space>eq<seq2seq4repair_space>RUNNING" ; private static final int OPERATION_TIMEOUT_MSILEC = 10000 ; static Compute compute ; public GCEOperations ( ) throws IOException , GeneralSecurityException , LoadBalancerExtensionException { } private void buildComputeEngineObject ( ) throws IOException , GeneralSecurityException { } public void createTargetPool ( String targetPoolName , String healthCheckName ) { } public void deleteTargetPool ( String targetPoolName ) { } public void createForwardingRule ( String forwardingRuleName , String targetPoolName , String protocol , String portRange ) { } public void deleteForwardingRule ( String forwardingRuleName ) { } public boolean isTargetPoolExists ( String targetPoolName ) { } public boolean isForwardingRuleExists ( String forwardingRuleName ) { } public TargetPool getTargetPool ( String targetPoolName ) { } private void addInstancesToTargetPool ( String targetPoolName , List < InstanceReference > instanceReferenceList ) { } public void removeInstancesFromTargetPool ( String targetPoolName , List < InstanceReference > instanceReferenceList ) { } public static InstanceList getInstanceList ( ) throws IOException { } public static String getInstanceURLFromName ( String instanceName ) { } public void setPortRangeToForwardingRule ( ) { } public void addInstancesToTargetPool ( List < String > instancesNamesList , String targetPoolName ) { } public void createHealthCheck ( String healthCheckName ) { } public boolean isHealthCheckExists ( String healthCheckName ) { } public HttpHealthCheck getHealthCheckFromName ( String healthCheckName ) { } public static String getHealthCheckURLFromName ( String healthCheckName ) { } public static HttpHealthCheckList getHealthCheckList ( ) { } private void waitForOperationCompletion ( String operationName ) { try { <START_BUG> while ( GCEOperations . compute . regionOperations ( ) . get ( GCEOperations . PROJECT_ID , GCEOperations . REGION_NAME , operationName ) . execute ( ) . getStatus ( ) . equals ( "DONE" ) ) { <END_BUG> Thread . sleep ( 1000 ) ; } } catch ( IOException e ) { e . printStackTrace ( ) ; } catch ( InterruptedException e ) { e . printStackTrace ( ) ; } } public void sampleMethodForAddingInstancesToTargetPool ( ) { } public void sampleMethodForRemovingInstancesToTargetPool ( ) { } No newline ; at end ; of file ; }

Fix:
while ( GCEOperations . compute . globalOperations ( ) . get ( GCEOperations . PROJECT_ID , operationName ) . execute ( ) . getStatus ( ) . equals ( "DONE" ) ) {