auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
<code>public boolean equals(Object obj) { if (obj == null) { return false; } <START> if (!JarRuntimeInfo.class.isAssignableFrom(obj.getClass())) { <END> return false; } JdbcRuntimeInfo other = (JdbcRuntimeInfo) obj; return super.equals(obj) && this.driverClassName.equals(other.driverClassName); }</code><technical_language>Some differences explained : <LINK_0></technical_language>

Target:
public boolean equals(Object obj) { if (obj == null) { return false; } if (this == obj) { return true; } if (!(obj instanceof JdbcRuntimeInfo)) { return false; } JdbcRuntimeInfo other = (JdbcRuntimeInfo) obj; return super.equals(obj) && this.driverClassName.equals(other.driverClassName); }
Source:
<code>@Override public E element() { lock.lock(); try { if (queue.isEmpty()) { throw new NoSuchElementException(); } return queue.peek(); } catch (IOException e) { QueueFile.<Error>getSneakyThrowable(e); <START> return null; <END> } finally { lock.unlock(); } }</code><technical_language>throws</technical_language>

Target:
@Override public E element() { lock.lock(); try { if (queue.isEmpty()) { throw new NoSuchElementException(); } return queue.peek(); } catch (IOException e) { throw QueueFile.<Error>getSneakyThrowable(e); } finally { lock.unlock(); } }
Source:
<code>public Process runServer() throws IOException { <START> final String serverConsoleLogPath = "/Users/amartinezman/Desktop/gm" + File.separator + host + "_" + port + "_consolelog"; <END> File logPath = new File(getCorfuServerLogPath(host, port)); if (!logPath.exists()) { logPath.mkdir(); } ProcessBuilder builder = new ProcessBuilder(); builder.command("sh", "-c", "bin/corfu_replication_server " + getOptionsString()); builder.directory(new File(CORFU_PROJECT_DIR)); Process corfuReplicationServerProcess = builder.start(); StreamGobbler streamGobbler = new StreamGobbler(corfuReplicationServerProcess.getInputStream(), serverConsoleLogPath); Executors.newSingleThreadExecutor().submit(streamGobbler); return corfuReplicationServerProcess; }</code><technical_language>remove</technical_language>

Target:
public Process runServer() throws IOException { final String serverConsoleLogPath = CORFU_LOG_PATH + File.separator + host + "_" + port + "_consolelog"; File logPath = new File(getCorfuServerLogPath(host, port)); if (!logPath.exists()) { logPath.mkdir(); } ProcessBuilder builder = new ProcessBuilder(); builder.command("sh", "-c", "bin/corfu_replication_server " + getOptionsString()); builder.directory(new File(CORFU_PROJECT_DIR)); Process corfuReplicationServerProcess = builder.start(); StreamGobbler streamGobbler = new StreamGobbler(corfuReplicationServerProcess.getInputStream(), serverConsoleLogPath); Executors.newSingleThreadExecutor().submit(streamGobbler); return corfuReplicationServerProcess; }
Source:
<code>private KeyHashIdentifier getReferenceToLockKey(KeyHashIdentifier lockKey) { KeyHashIdentifier referenceToLockKey = null; synchronized (weakReferencesTolocks) { for (KeyHashIdentifier keyInSet : weakReferencesTolocks.keySet()) { if (keyInSet.equals(lockKey)) { <START> referenceToLockKey = keyInSet; <END> break; } } } return referenceToLockKey; }</code><technical_language>return keyInSet set referenceToLockKey return null line 105</technical_language>

Target:
private KeyHashIdentifier getReferenceToLockKey(KeyHashIdentifier lockKey) { synchronized (weakReferencesTolocks) { for (KeyHashIdentifier keyInSet : weakReferencesTolocks.keySet()) { if (keyInSet.equals(lockKey)) { return keyInSet; } } } return null; }
Source:
<code>private void processVotes(final Song previousSong) { <START> AtomicInteger nettoVotes = new AtomicInteger(); <END> this.votes.values().stream().forEach((vote) -> { if (vote.equals(Vote.LIKE)) { nettoVotes.incrementAndGet(); } else { nettoVotes.decrementAndGet(); } }); if (nettoVotes.get() < 0) { final RoomDAO roomDAO = this.roomDAOProvider.get(); final Room room = roomDAO.findById(id); previousSong.addExclusionRoom(room); } this.votes.clear(); }</code><technical_language>If integer accessed multiple threads, is need atomic</technical_language>

Target:
private void processVotes(final Song previousSong) { int nettoVotes = this.votes.values().stream() .mapToInt(Vote::getValue) .sum(); if (nettoVotes < 0) { final RoomDAO roomDAO = this.roomDAOProvider.get(); final Room room = roomDAO.findById(id); previousSong.addExclusionRoom(room); } this.votes.clear(); }
Source:
<code>public static boolean isValidOverBlackListPatterns(String input, String... blackListPatterns) { if (ArrayUtils.isEmpty(blackListPatterns)) { throw new IllegalArgumentException("Should provide at least one black list pattern"); } boolean isValid = false; <START> if (input != null) { <END> for (String key : blackListPatterns) { if (validatorConfig.getPattern(key) != null) { isValid = !validatorConfig.getPattern(key).matcher(input).matches(); if (!isValid) { break; } } } } return isValid; }</code><technical_language>if input is null valid for blacklist patterns ? I throw illegal argument exception consider null valid. I prefer considered valid caller need unnecessarily check for null of input time</technical_language>

Target:
public static boolean isValidOverBlackListPatterns(String input, String... blackListPatterns) { if (ArrayUtils.isEmpty(blackListPatterns)) { throw new IllegalArgumentException("Should provide at least one black list pattern"); } if (StringUtils.isEmpty(input)) { return true; } boolean isValid = false; for (String key : blackListPatterns) { if (validatorConfig.getPattern(key) != null) { isValid = !validatorConfig.getPattern(key).matcher(input).matches(); if (!isValid) { break; } } } return isValid; }
Source:
<code>public void onButtonPressed(ThingUID bridge, LIRCButtonEvent buttonEvent) { <START> <END> if (remoteName.equals(buttonEvent.getRemote())) { logger.debug("Remote {}: Button pressed times.", remoteName, buttonEvent.getButton(), buttonEvent.getRepeats() + 1); updateStatus(ThingStatus.ONLINE); updateState(CHANNEL_BUTTON, new StringType(buttonEvent.getButton())); } }</code><technical_language>blank lines in</technical_language>

Target:
public void onButtonPressed(ThingUID bridge, LIRCButtonEvent buttonEvent) { if (remoteName.equals(buttonEvent.getRemote())) { logger.debug("Remote {}: Button pressed times.", remoteName, buttonEvent.getButton(), buttonEvent.getRepeats() + 1); updateStatus(ThingStatus.ONLINE); triggerChannel(LIRCBindingConstants.CHANNEL_EVENT, buttonEvent.getButton()); } }
Source:
<code>private static void logCodeMiningProviderException(Throwable e) { if (e != null && (e instanceof CancellationException || (e.getCause() != null && e.getCause() instanceof CancellationException))) { return; } try { String PLUGIN_ID= "org.eclipse.jface.text"; ILog log= Platform.getLog(Platform.getBundle(PLUGIN_ID)); log.log(new Status(IStatus.ERROR, PLUGIN_ID, IStatus.OK, e.getMessage(), e)); <START> } catch (Exception ex) { <END> } }</code><technical_language>Do need this part of this patch? If fixes another issue, a patch</technical_language>

Target:
private static void logCodeMiningProviderException(Throwable e) { if (e != null && (e instanceof CancellationException || (e.getCause() != null && e.getCause() instanceof CancellationException))) { return; } String PLUGIN_ID= "org.eclipse.jface.text"; Bundle plugin= Platform.getBundle(PLUGIN_ID); if (plugin != null) { ILog log= Platform.getLog(plugin); log.log(new Status(IStatus.ERROR, PLUGIN_ID, IStatus.OK, e.getMessage(), e)); } else { e.printStackTrace(); } }
Source:
<code>protected void ExecuteVdsBrokerCommand() { String volumeName = getParameters().getVolumeName(); List<GlusterBrickEntity> bricksList = getParameters().getBricks(); List<String> brickNames = new ArrayList<String>(); for (GlusterBrickEntity brick : bricksList) { brickNames.add(brick.getQualifiedName()); <START> } <END> result = getBroker().glusterVolumeRemoveBrickStatus(volumeName, (String[])brickNames.toArray(), getParameters().getReplicaCount()); proceedProxyReturnValue(); GlusterVolumeTaskStatusEntity entity = result.getStatusDetails(); entity.setStatusTime(new Date()); setReturnValue(entity); }</code><technical_language>build String[] here? Btw, a findbug violation casting String[]</technical_language>

Target:
protected void ExecuteVdsBrokerCommand() { String volumeName = getParameters().getVolumeName(); List<GlusterBrickEntity> bricksList = getParameters().getBricks(); String[] brickNames = new String[bricksList.size()]; for (int count = 0; count < bricksList.size(); count++) { brickNames[count] = bricksList.get(count).getQualifiedName(); } result = getBroker().glusterVolumeRemoveBrickStatus(volumeName, brickNames); proceedProxyReturnValue(); GlusterVolumeTaskStatusEntity entity = result.getStatusDetails(); entity.setStatusTime(new Date()); setReturnValue(entity); }
Source:
<code>void testIsUsAchBankForeignFormCanadaBank() { achService.setPaymentWorksFormModeService(buildMockPaymentWorksFormModeService(true)); pmwVendor.setBankAddressCountry(PaymentWorksConstants.PaymentWorksPurchaseOrderCountryFipsOption.CANADA.getPmwCountryOptionAsString()); boolean actualIsUsBankAccount = achService.isUsAchBank(pmwVendor, reportData); assertFalse(actualIsUsBankAccount); assertEquals(0, reportData.getRecordsThatCouldNotBeProcessedSummary().getRecordCount()); assertEquals(0, reportData.getPmwVendorAchsThatCouldNotBeProcessed().size()); assertEquals(1, reportData.getRecordsWithForeignAchSummary().getRecordCount()); List<PaymentWorksBatchReportVendorItem> foreignAchItems = reportData.getForeignAchItems(); assertEquals(1, foreignAchItems.size()); List<String> foreignAchErrorMessages = foreignAchItems.get(0).getErrorMessages(); assertEquals(1, foreignAchErrorMessages.size()); <START> String actualErrorMmessage = foreignAchErrorMessages.get(0); <END> assertEquals("The bank has a country code of Canada. We can only create ACH records for banks that have a US address", actualErrorMmessage); }</code><technical_language>Minor typo in variable name; extra unneeded "m"</technical_language>

Target:
void testIsUsAchBankForeignFormCanadaBank() { achService.setPaymentWorksFormModeService(buildMockPaymentWorksFormModeService(true)); pmwVendor.setBankAddressCountry(PaymentWorksConstants.PaymentWorksPurchaseOrderCountryFipsOption.CANADA.getPmwCountryOptionAsString()); boolean actualIsUsBankAccount = achService.isUsAchBank(pmwVendor, reportData); assertFalse(actualIsUsBankAccount); assertEquals(0, reportData.getRecordsThatCouldNotBeProcessedSummary().getRecordCount()); assertEquals(0, reportData.getPmwVendorAchsThatCouldNotBeProcessed().size()); assertEquals(1, reportData.getRecordsWithForeignAchSummary().getRecordCount()); List<PaymentWorksBatchReportVendorItem> foreignAchItems = reportData.getForeignAchItems(); assertEquals(1, foreignAchItems.size()); List<String> foreignAchErrorMessages = foreignAchItems.get(0).getErrorMessages(); assertEquals(1, foreignAchErrorMessages.size()); String actualErrorMessage = foreignAchErrorMessages.get(0); assertEquals("The bank has a country code of Canada. We can only create ACH records for banks that have a US address", actualErrorMessage); }
Source:
<code>public void setFirstReference(PDOMLinkage linkage, PDOMName name) throws CoreException { <START> if (linkage.equals(getLinkage())) <END> setFirstReference(name); else new PDOMExternalReferencesList(getPDOM(), record + FIRST_EXTREF_OFFSET).setFirstReference(linkage, name); }</code><technical_language>'If" statements 'else' branches curly braces branches</technical_language>

Target:
public void setFirstReference(PDOMLinkage linkage, PDOMName name) throws CoreException { if (linkage.equals(getLinkage())) { setFirstReference(name); } else { new PDOMExternalReferencesList(getPDOM(), record + FIRST_EXTREF_OFFSET).setFirstReference(linkage, name); } }
Source:
<code>@Test public void checkDockerExists() { boolean dockerExists = new File("./Docker").exists() || <START> new File("./docker/Docker").exists(); <END> assertTrue(dockerExists); }</code><technical_language>docker/Dockerfile</technical_language>

Target:
@Test public void checkDockerExists() { boolean dockerExists = new File("./Dockerfile").exists() || new File("./docker/Dockerfile").exists(); assertTrue(dockerExists); }
Source:
<code>public void testSchemaMetadataScan() throws SQLException { long ts = nextTimestamp(); ensureTableCreated(getUrl(), CUSTOM_ENTITY_DATA_FULL_NAME, null, ts); ensureTableCreated(getUrl(), PTSDB_NAME, null, ts); Properties props = new Properties(); props.setProperty(PhoenixRuntime.CURRENT_SCN_ATTRIB, Long.toString(ts + 5)); Connection conn = DriverManager.getConnection(getUrl(), props); DatabaseMetaData dbmd = conn.getMetaData(); ResultSet rs; rs = dbmd.getSchemas(null, CUSTOM_ENTITY_DATA_SCHEMA_NAME); assertTrue(rs.next()); assertEquals(rs.getString(1),CUSTOM_ENTITY_DATA_SCHEMA_NAME); assertEquals(rs.getString(2),null); assertFalse(rs.next()); rs = dbmd.getSchemas(null, null); assertTrue(rs.next()); <START> assertEquals(rs.getString("TABLE_SCHEM"),CUSTOM_ENTITY_DATA_SCHEMA_NAME); <END> assertEquals(rs.getString("TABLE_CATALOG"),null); assertFalse(rs.next()); }</code><technical_language>Is a reason lines removed</technical_language>

Target:
public void testSchemaMetadataScan() throws SQLException { Properties props = new Properties(); props.setProperty(QueryServices.IS_NAMESPACE_MAPPING_ENABLED, Boolean.toString(true)); Connection conn = DriverManager.getConnection(getUrl(), props); conn.createStatement().execute("CREATE SCHEMA " + CUSTOM_ENTITY_DATA_SCHEMA_NAME); DatabaseMetaData dbmd = conn.getMetaData(); ResultSet rs; rs = dbmd.getSchemas(null, CUSTOM_ENTITY_DATA_SCHEMA_NAME); assertTrue(rs.next()); assertEquals(rs.getString(1),CUSTOM_ENTITY_DATA_SCHEMA_NAME); assertEquals(rs.getString(2),null); assertFalse(rs.next()); rs = dbmd.getSchemas(null, null); assertTrue(rs.next()); assertEquals(rs.getString("TABLE_SCHEM"),CUSTOM_ENTITY_DATA_SCHEMA_NAME); assertEquals(rs.getString("TABLE_CATALOG"),null); assertFalse(rs.next()); }
Source:
<code>public void enqueue(Lifespan lifespan, int partitionNumber, List<SerializedPage> pages) { <START> requireNonNull(lifespan, "lifespan is null"); <END> checkState(partitionNumber == 0, "Expected partition number to be zero"); checkState(lifespanCompletionCallback != null, "lifespanCompletionCallback has to be set before starting enqueue data"); enqueue(lifespan, pages); }</code><technical_language>Ditto checks. I need duplicate them</technical_language>

Target:
public void enqueue(Lifespan lifespan, int partitionNumber, List<SerializedPage> pages) { checkState(partitionNumber == 0, "Expected partition number to be zero"); enqueue(lifespan, pages); }
Source:
<code>protected static Comparator<Method> ignoringDeclaringClassAndMethodName() { return new Comparator<Method>() { @Override <START> public int compare(Method o1, Method o2) { <END> boolean equal = (ACCESS_MODIFIERS & o1.getModifiers() & o2.getModifiers()) != 0; equal = equal && o1.getReturnType().equals(o2.getReturnType()); Class<?>[] pTypes1 = o1.getParameterTypes(); Class<?>[] pTypes2 = o2.getParameterTypes(); equal = equal && pTypes1.length == pTypes2.length; if (equal) { for (int i = 0; i < pTypes1.length; i++) { equal = equal && pTypes1[i].equals(pTypes2[i]); } } return equal ? 0 : 1; } }; }</code><technical_language>rename o1 method1 o2 method2 for code readability</technical_language>

Target:
protected static Comparator<Method> ignoringDeclaringClassAndMethodName() { return internalMethodComparator(true, false, true); }
Source:
<code>public TestProject(final boolean remove, String path, boolean insidews) throws CoreException { IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot(); Path ppath = new Path(path); String projectName = ppath.lastSegment(); URI locationURI; URI top; if (insidews) { top = root.getRawLocationURI(); } else { File tempName; try { tempName = testUtils.createTempDir("wssupplement"); } catch (IOException e) { throw new RuntimeException(e); } top = URIUtil.toURI(tempName.getAbsolutePath()); } <START> if (!ppath.lastSegment().equals(path)) { <END> locationURI = URIUtil.toURI(URIUtil.toPath(top).append(path)); } else locationURI = null; project = root.getProject(projectName); if (remove) project.delete(true, null); IProjectDescription description = ResourcesPlugin.getWorkspace() .newProjectDescription(projectName); description.setName(projectName); description.setLocationURI(locationURI); project.create(description, null); project.open(null); location = project.getLocation().toOSString(); javaProject = JavaCore.create(project); IFolder binFolder = createBinFolder(); setJavaNature(); javaProject.setRawClasspath(new IClasspathEntry[0], null); createOutputFolder(binFolder); addSystemLibraries(); }</code><technical_language>If path is simple, i.e. project name, ppath.lastSegment().equals(path) is true a consequence locatioURI is set null (the default location). parameter insidews is account in this case. Please fix that. I (!ppath.lastSegment().equals(path) || !insidews) work</technical_language>

Target:
public TestProject(final boolean remove, String path, boolean insidews) throws CoreException { IWorkspaceRoot root = ResourcesPlugin.getWorkspace().getRoot(); IProjectDescription description = createDescription(remove, path, insidews, root); project = root.getProject(description.getName()); if (remove) project.delete(true, null); IPath locationBefore = description.getLocation(); if (locationBefore == null) locationBefore = root.getRawLocation().append(path); location = locationBefore.toOSString(); project.create(description, null); project.open(null); javaProject = JavaCore.create(project); IFolder binFolder = createBinFolder(); setJavaNature(); javaProject.setRawClasspath(new IClasspathEntry[0], null); createOutputFolder(binFolder); addSystemLibraries(); }
Source:
<code><START> protected void addLocation(Location location) { <END> if (location != null) { allLocations.add(location); } }</code><technical_language>Location is related activity. Therefore, I sense add location here. needs assign activity activities locations</technical_language>

Target:
private void addLocation(Location location) { if (location != null) { allLocations.add(location); } }
Source:
<code>public DownloadResponse head(String siteUrl) throws IOException, ReCaptchaException { final HttpsURLConnection con = (HttpsURLConnection) new URL(siteUrl).openConnection(); try { con.setRequestMethod("HEAD"); con.setConnectTimeout(30 * 1000); con.setReadTimeout(30 * 1000); <START> con.setRequestProperty("User-Agent", USER_AGENT); <END> if (!TextUtils.isEmpty(mCookies)) { con.setRequestProperty("Cookie", mCookies); } } catch (Exception e) { if (con.getResponseCode() == 429) { throw new ReCaptchaException("reCaptcha Challenge requested", con.getURL().toString()); } throw new IOException(con.getResponseCode() + " " + con.getResponseMessage(), e); } return new DownloadResponse(con.getResponseCode(), null, con.getHeaderFields()); }</code><technical_language>if this is temporary, OkHttp's client: java @Override public DownloadResponse head(String siteUrl) throws IOException, ReCaptchaException { final Request request = new Request.Builder() .head().url(siteUrl) .addHeader("User-Agent", USER_AGENT) .build(); final Response response = client.newCall(request).execute(); if (response.code() == 429) { throw new ReCaptchaException("reCaptcha Challenge requested", siteUrl); } return new DownloadResponse(response.code(), null, response.headers().toMultimap()); }</technical_language>

Target:
public DownloadResponse head(String siteUrl) throws IOException, ReCaptchaException { final Request request = new Request.Builder() .head().url(siteUrl) .addHeader("User-Agent", USER_AGENT) .build(); final Response response = client.newCall(request).execute(); if (response.code() == 429) { throw new ReCaptchaException("reCaptcha Challenge requested", siteUrl); } return new DownloadResponse(response.code(), null, response.headers().toMultimap()); }
Source:
<code>public void onSaveInstanceState(Bundle outState) { super.onSaveInstanceState(outState); outState.putString("findinpage_text", findInPageInput.getText().toString()); <START> outState.putString("findinpage_enabled", findInPageInput.getText().toString()); <END> }</code><technical_language>Is this read anywhere? saving twice</technical_language>

Target:
public void onSaveInstanceState(Bundle outState) { super.onSaveInstanceState(outState); outState.putString("findinpage_text", findInPageInput.getText().toString()); }
Source:
<code>public void cleanup() { File tempFile = fTempFile; if (tempFile != null) { <START> tempFile.delete(); <END> } }</code><technical_language>is a guarantee statement a if is executed preempted. statement [1]. null-check fTempFile here. good practice extract a local variable in general, a small method thing, fine, imo. [1] I remember this I a class a looong time ago, I find references online... compiler agree though. a bug crazy? :O</technical_language>

Target:
public void cleanup() { if (fTempFile != null) { fTempFile.delete(); } }
Source:
<code>private static void watch(String path) { final BlockingQueue<FileWatchEvent> eventQueue = new ArrayBlockingQueue<FileWatchEvent>(16); Thread processorThread = new Thread(new Runnable() { @Override public void run() { while (!Thread.currentThread().isInterrupted()) { FileWatchEvent event; try { event = eventQueue.take(); <START> } catch (InterruptedException e) { <END> break; } if (event.getType() == FileWatchEvent.Type.FAILURE) { Throwable failure = event.getFailure(); assert failure != null; failure.printStackTrace(); } else { System.out.printf("Change detected: %s / '%s'%n", event.getType(), event.getPath()); } } } }, "File watcher client"); processorThread.setDaemon(true); processorThread.start(); FileWatcher watcher = createWatcher(path, eventQueue); try { System.out.println("Waiting - type ctrl-d to exit ..."); while (true) { int ch = System.in.read(); if (ch < 0) { break; } } } catch (Exception e) { throw new RuntimeException(e); } finally { try { watcher.close(); } catch (IOException e) { e.printStackTrace(); } processorThread.interrupt(); } System.out.println("Done"); }</code><technical_language>thread clear interrupted flag here, right</technical_language>

Target:
private static void watch(String path) throws InterruptedException { final BlockingQueue<FileWatchEvent> eventQueue = new ArrayBlockingQueue<FileWatchEvent>(16); Thread processorThread = new Thread(new Runnable() { @Override public void run() { while (!Thread.currentThread().isInterrupted()) { FileWatchEvent event; try { event = eventQueue.take(); } catch (InterruptedException e) { break; } if (event.getType() == FileWatchEvent.Type.FAILURE) { Throwable failure = event.getFailure(); assert failure != null; failure.printStackTrace(); } else { System.out.printf("Change detected: %s / '%s'%n", event.getType(), event.getPath()); } } } }, "File watcher client"); processorThread.setDaemon(true); processorThread.start(); FileWatcher watcher = createWatcher(path, eventQueue); try { System.out.println("Waiting - type ctrl-d to exit ..."); while (true) { int ch = System.in.read(); if (ch < 0) { break; } } } catch (Exception e) { throw new RuntimeException(e); } finally { try { watcher.close(); } catch (IOException e) { e.printStackTrace(); } processorThread.interrupt(); } System.out.println("Done"); }
Source:
<code>public SettableFuture schedule(SourcePartitionedScheduler scheduler) { checkState(initialScheduled); List<Lifespan> recentlyCompletedDriverGroups; synchronized (this) { recentlyCompletedDriverGroups = ImmutableList.copyOf(this.recentlyCompletedDriverGroups); this.recentlyCompletedDriverGroups.clear(); newDriverGroupReady = SettableFuture.create(); } <START> if (!recentlyCompletedDriverGroups.isEmpty()) { <END> for (Lifespan driverGroup : recentlyCompletedDriverGroups) { IntListIterator driverGroupsIterator = nodeToDriverGroupsMap.get(driverGroupToNodeMap.get(driverGroup.getId())); if (!driverGroupsIterator.hasNext()) { continue; } int driverGroupId = driverGroupsIterator.nextInt(); scheduler.startLifespan(Lifespan.driverGroup(driverGroupId), partitionHandles.get(driverGroupId)); } } return newDriverGroupReady; }</code><technical_language>This if do</technical_language>

Target:
public SettableFuture schedule(SourcePartitionedScheduler scheduler) { checkState(initialScheduled); List<Lifespan> recentlyCompletedDriverGroups; synchronized (this) { recentlyCompletedDriverGroups = ImmutableList.copyOf(this.recentlyCompletedDriverGroups); this.recentlyCompletedDriverGroups.clear(); newDriverGroupReady = SettableFuture.create(); } for (Lifespan driverGroup : recentlyCompletedDriverGroups) { IntListIterator driverGroupsIterator = nodeToDriverGroupsMap.get(driverGroupToNodeMap.get(driverGroup.getId())); if (!driverGroupsIterator.hasNext()) { continue; } int driverGroupId = driverGroupsIterator.nextInt(); scheduler.startLifespan(Lifespan.driverGroup(driverGroupId), partitionHandles.get(driverGroupId)); } return newDriverGroupReady; }
Source:
<code>public String toString() { <START> return "Pair[" + key + ", " + value + "]"; <END> }</code><technical_language>In toString() log messages, "[" denote lists, collections, arrays, etc. "(" denote fields. change this into: return "Pair(" + key + ", " + + ")";</technical_language>

Target:
public String toString() { return "Pair(" + key + ", " + value + ")"; }
Source:
<code>private static ClientRegistration.Builder getBuilder(String issuer, Supplier<ClientRegistration.Builder>... suppliers) { String errorMessage = "Unable to resolve Configuration with the provided Issuer of \"" + issuer + "\""; for (Supplier<ClientRegistration.Builder> supplier : suppliers) { try { <START> ClientRegistration.Builder builder = supplier.get(); <END> return builder; } catch (HttpClientErrorException e) { if (!e.getStatusCode().is4xxClientError()) { throw e; } } catch (IllegalArgumentException | IllegalStateException e) { throw e; } catch (RuntimeException e) { throw new IllegalArgumentException(errorMessage, e); } } throw new IllegalArgumentException(errorMessage); }</code><technical_language>simplify this a bit: suggestion return supplier.get();</technical_language>

Target:
private static ClientRegistration.Builder getBuilder(String issuer, Supplier<ClientRegistration.Builder>... suppliers) { String errorMessage = "Unable to resolve Configuration with the provided Issuer of \"" + issuer + "\""; for (Supplier<ClientRegistration.Builder> supplier : suppliers) { try { return supplier.get(); } catch (HttpClientErrorException e) { if (!e.getStatusCode().is4xxClientError()) { throw e; } } catch (IllegalArgumentException | IllegalStateException e) { throw e; } catch (RuntimeException e) { throw new IllegalArgumentException(errorMessage, e); } } throw new IllegalArgumentException(errorMessage); }
Source:
<code>public void updateRoutingTable(final EMRoutingTableUpdate routingTableUpdate) { checkInitialization(); final int oldOwnerId = routingTableUpdate.getOldOwnerId(); final int newOwnerId = routingTableUpdate.getNewOwnerId(); final String newEvalId = routingTableUpdate.getNewEvalId(); storeIdToEndpointId.put(newOwnerId, newEvalId); final int blockId = routingTableUpdate.getBlockId(); final int actualOldOwnerId = blockIdToStoreId.put(blockId, newOwnerId); if (oldOwnerId != actualOldOwnerId) { LOG.log(Level.FINER, "Mapping was stale about block {0}", blockId); } else { <START> LOG.log(Level.FINE, "Mapping table in server resolver is updated"); <END> } if (!blockIdToStoreId.containsValue(oldOwnerId)) { final String deletedServerId = storeIdToEndpointId.remove(oldOwnerId); if (deletedServerId != null && ongoingSyncs.remove(deletedServerId)) { msgSender.get().sendRoutingTableSyncReplyMsg(deletedServerId); } } }</code><technical_language>move this statement of else clause. Also, do a more detailed log message? For example, log information blockId, & new owner Id</technical_language>

Target:
public void updateRoutingTable(final EMRoutingTableUpdate routingTableUpdate) { checkInitialization(); final int oldOwnerId = routingTableUpdate.getOldOwnerId(); final int newOwnerId = routingTableUpdate.getNewOwnerId(); final String newEvalId = routingTableUpdate.getNewEvalId(); storeIdToEndpointId.put(newOwnerId, newEvalId); final int blockId = routingTableUpdate.getBlockId(); final int actualOldOwnerId = blockIdToStoreId.put(blockId, newOwnerId); if (oldOwnerId != actualOldOwnerId) { LOG.log(Level.WARNING, "Mapping was stale about block {0}. ExpectedOldOwnerId: {1}, ActualOldOwnerId: {2}", new Object[]{blockId, oldOwnerId, actualOldOwnerId}); } synchronized (this) { final Set<Integer> blockIdsInOldStore = storeIdToBlockIds.get(actualOldOwnerId); blockIdsInOldStore.remove(blockId); if (blockIdsInOldStore.isEmpty()) { storeIdToBlockIds.remove(actualOldOwnerId); final String deletedServerId = storeIdToEndpointId.remove(actualOldOwnerId); LOG.log(Level.INFO, "Server {0} is deleted from routing table", deletedServerId); if (ongoingSyncs.remove(deletedServerId)) { msgSender.get().sendRoutingTableSyncReplyMsg(deletedServerId); } } Set<Integer> blockIdsInNewStore = storeIdToBlockIds.get(newOwnerId); if (blockIdsInNewStore == null) { blockIdsInNewStore = storeIdToBlockIds.put(newOwnerId, new HashSet<>()); } blockIdsInNewStore.add(blockId); } LOG.log(Level.FINE, "Mapping table in server resolver is updated." + " BlockId: {0}, OldOwnerId: {1}, NewOwnerId {2}", new Object[]{blockId, actualOldOwnerId, newOwnerId}); }
Source:
<code>public CompositeDisposable(@NonNull Iterable<? extends Disposable> disposables) { <START> ObjectHelper.requireNonNull(disposables, "Disposables are null"); <END> this.resources = new OpenHashSet<Disposable>(); for (Disposable d : disposables) { ObjectHelper.requireNonNull(d, "Disposable item in Disposables is null"); this.resources.add(d); } }</code><technical_language>disposables is null</technical_language>

Target:
public CompositeDisposable(@NonNull Iterable<? extends Disposable> disposables) { ObjectHelper.requireNonNull(disposables, "disposables is null"); this.resources = new OpenHashSet<Disposable>(); for (Disposable d : disposables) { ObjectHelper.requireNonNull(d, "A Disposable item in the disposables sequence is null"); this.resources.add(d); } }
Source:
<code>static Map<String, String> parseZkJsonAndPopulateZkInfo(String zkLayoutJsonString) throws JSONException { Map<String, String> dataCenterToZkAddress = new HashMap<>(); JSONObject root = new JSONObject(zkLayoutJsonString); <START> JSONArray all = (root).getJSONArray(ZKINFO_STR); <END> for (int i = 0; i < all.length(); i++) { JSONObject entry = all.getJSONObject(i); dataCenterToZkAddress.put(entry.getString(DATACENTER_STR), entry.getString(ZKCONNECTSTR_STR)); } return dataCenterToZkAddress; }</code><technical_language>For curiosity, parenthesis is needed</technical_language>

Target:
static Map<String, String> parseZkJsonAndPopulateZkInfo(String zkLayoutJsonString) throws JSONException { Map<String, String> dataCenterToZkAddress = new HashMap<>(); JSONObject root = new JSONObject(zkLayoutJsonString); JSONArray all = root.getJSONArray(ZKINFO_STR); for (int i = 0; i < all.length(); i++) { JSONObject entry = all.getJSONObject(i); dataCenterToZkAddress.put(entry.getString(DATACENTER_STR), entry.getString(ZKCONNECTSTR_STR)); } return dataCenterToZkAddress; }
Source:
<code>public CloudConfig(VerifiableProperties verifiableProperties) { <START> vcrClusterZkConnectString = verifiableProperties.getString("vcr.cluster.zk.connect.string", ""); <END> vcrClusterName = verifiableProperties.getString("vcr.cluster.name"); vcrSslPort = verifiableProperties.getInteger("vcr.ssl.port", null); vcrReplicaMountPathPrefix = verifiableProperties.getString("vcr.replica.mount.path.prefix", "/tmp/vcr/"); }</code><technical_language>Remove default</technical_language>

Target:
public CloudConfig(VerifiableProperties verifiableProperties) { vcrClusterZkConnectString = verifiableProperties.getString("vcr.cluster.zk.connect.string", VCR_CLUSTER_ZK_CONNECT_STRING); vcrClusterName = verifiableProperties.getString("vcr.cluster.name", VCR_CLUSTER_NAME); vcrSslPort = verifiableProperties.getInteger("vcr.ssl.port", 6668); vcrReplicaMountPathPrefix = verifiableProperties.getString("vcr.replica.mount.path.prefix", VCR_REPLICA_MOUNT_PATH_PREFIX); }
Source:
<code>public void testEvictCustomKeyValue() { CountMarshallingPojo.reset(); int expectedWrites = 0; int expectedReads = 0; for (int i = 0; i < CACHE_SIZE * 2; i++) { <START> CountMarshallingPojo p1 = new CountMarshallingPojo((int) Util.random(2000)); <END> CountMarshallingPojo p2 = new CountMarshallingPojo(24); Object old = cache.put(p1, p2); if (old != null) expectedReads++; expectedWrites += 2; } assertEquals(CACHE_SIZE, cache.getAdvancedCache().getDataContainer().size()); assertEquals(expectedWrites, CountMarshallingPojo.getMarshallCount()); assertEquals(expectedReads, CountMarshallingPojo.getUnmarshallCount()); }</code><technical_language>random number? bigger problem is CountMarshallingPojo static fields for marshall count, breaks 2 of tests run in parallel. a custom raw marshaller, a marshaller instance in test, a test name field maintain a map of marshall counts test</technical_language>

Target:
public void testEvictCustomKeyValue() { EvictionPojoMarshaller.resetStats(); int expectedWrites = 0; int expectedReads = 0; for (int i = 0; i < CACHE_SIZE * 2; i++) { EvictionPojo p1 = new EvictionPojo(); p1.i = (int) Util.random(2000); EvictionPojo p2 = new EvictionPojo(); p2.i = 24; Object old = cache.put(p1, p2); if (old != null) expectedReads++; expectedWrites += 2; } assertEquals(CACHE_SIZE, cache.getAdvancedCache().getDataContainer().size()); assertEquals(expectedWrites, EvictionPojoMarshaller.writes.get()); assertEquals(expectedReads, EvictionPojoMarshaller.reads.get()); }
Source:
<code>public void close(SelectionKey key) { SocketChannel socketChannel = channel(key); Transmissions transmissions = transmissions(key); <START> <END> if (transmissions != null) { logger.debug("Closing connection from {}", transmissions.connectionId); this.disconnected.add(transmissions.connectionId); this.keys.remove(transmissions.connectionId); activeConnections.set(this.keys.size()); transmissions.clearReceive(); transmissions.clearSend(); } key.attach(null); key.cancel(); try { socketChannel.socket().close(); socketChannel.close(); } catch (IOException e) { logger.error("Exception closing connection to node {}:", transmissions.connectionId, e); } this.metrics.selectorConnectionClosed.inc(); }</code><technical_language>avoid new lines is a reason</technical_language>

Target:
private void close(SelectionKey key) { SocketChannel socketChannel = channel(key); Transmissions transmissions = transmissions(key); if (transmissions != null) { logger.debug("Closing connection from {}", transmissions.connectionId); this.disconnected.add(transmissions.connectionId); this.keyMap.remove(transmissions.connectionId); activeConnections.set(this.keyMap.size()); transmissions.clearReceive(); transmissions.clearSend(); } key.attach(null); key.cancel(); try { socketChannel.socket().close(); socketChannel.close(); } catch (IOException e) { logger.error("Exception closing connection to node {}:", transmissions.connectionId, e); } this.metrics.selectorConnectionClosed.inc(); }
Source:
<code>public void storeConfig() throws IOException { final Resource config = configPathDir.get(CONFIG_FILE_NAME); OutputStream fos = config.out(); try { this.configuration.store(fos, ""); } finally { <START> fos.close(); <END> } }</code><technical_language>@NielsCharlier try-with-resources</technical_language>

Target:
public void storeConfig() throws IOException { Resource config = configPathDir.get(CONFIG_FILE_NAME); try (OutputStream fos = config.out()) { this.configuration.store(fos, ""); } }
Source:
<code>public void aboutToBeShown() { super.aboutToBeShown(); this.selectionListener = new SelectionListener() { @Override public void widgetSelected(SelectionEvent e) { IStructuredSelection selection = comboViewer.getStructuredSelection(); Object newValue = selection.getFirstElement(); controller.updateValue(newValue); } @Override public void widgetDefaultSelected(SelectionEvent e) { } }; this.combo.addSelectionListener(this.selectionListener); this.controller.onNewValue(new IConsumer<Object>() { @Override public void apply(Object value) { if (!combo.isDisposed() && !(combo.getText() != null && combo.getText().equals(value))) { final ISelection selection; if (value != null) { selection = new StructuredSelection(value); } else { selection = null; } comboViewer.setSelection(selection); if <START> (isEnabled() && <END> !combo.isEnabled()) { combo.setEnabled(true); } } } }); this.controller.onNewCandidates(new IConsumer<List<Object>>() { @Override public void apply(List<Object> value) { if (!combo.isDisposed()) { if (value != null) { comboViewer.setInput(value.toArray()); } else { comboViewer.setInput(null); } if (isEnabled() && !combo.isEnabled()) { combo.setEnabled(true); } } } }); }</code><technical_language>radio</technical_language>

Target:
public void aboutToBeShown() { super.aboutToBeShown(); this.selectionListener = new SelectionListener() { @Override public void widgetSelected(SelectionEvent e) { IStructuredSelection selection = comboViewer.getStructuredSelection(); Object newValue = selection.getFirstElement(); controller.updateValue(newValue); } @Override public void widgetDefaultSelected(SelectionEvent e) { } }; this.combo.addSelectionListener(this.selectionListener); this.controller.onNewValue(new IConsumer<Object>() { @Override public void apply(Object value) { if (!combo.isDisposed() && !(combo.getText() != null && combo.getText().equals(value))) { final ISelection selection; if (value != null) { selection = new StructuredSelection(value); } else { selection = null; } comboViewer.setSelection(selection); if (!combo.isEnabled()) { combo.setEnabled(true); } } } }); this.controller.onNewCandidates(new IConsumer<List<Object>>() { @Override public void apply(List<Object> value) { if (!combo.isDisposed()) { if (value != null) { comboViewer.setInput(value.toArray()); } else { comboViewer.setInput(null); } if (!combo.isEnabled()) { combo.setEnabled(true); } } } }); }
Source:
<code>public String updateClasses(IResourceClass[] resourceClasses) { boolean different = false; if (this.resourceClasses.length != resourceClasses.length) different = true; else for (int i = 0; i < this.resourceClasses.length; ++i) { if (!this.resourceClasses[i].getId().equals(resourceClasses[i].getId()) || !this.resourceClasses[i].getHunamDescription().equals(resourceClasses[i].getHunamDescription())) { different = true; break; } } if (!different) return fResourceClassId; this.resourceClasses = resourceClasses; fResourceClassCombo.removeAll(); <START> int width = populateCombo(); <END> toolItem.setWidth(width + COMBO_TRIM_WIDTH); return fResourceClassId; }</code><technical_language>check if resourceClasses is empty in case, set width manually, is done in fill(). Currently test is a problem: Run debug sessions. Display a resource class. Select other debug session => Combo box is resized small resize anymore</technical_language>

Target:
public String updateClasses(IResourceClass[] resourceClasses) { boolean different = false; if (this.resourceClasses.length != resourceClasses.length) different = true; else for (int i = 0; i < this.resourceClasses.length; ++i) { if (!this.resourceClasses[i].getId().equals(resourceClasses[i].getId()) || !this.resourceClasses[i].getHumanDescription().equals(resourceClasses[i].getHumanDescription())) { different = true; break; } } if (!different) return fResourceClassId; this.resourceClasses = resourceClasses; fResourceClassCombo.removeAll(); int width = populateCombo(); toolItem.setWidth(width); return fResourceClassId; }
Source:
<code>public void slightlyOccupiedAABBTest() { Level check = new Level(emptyPlayer, emptyUnit, new Grid<>(Arrays.asList( Cell.WALL, Cell.WALL, Cell.WALL, Cell.WALL, Cell.EMPTY, Cell.WALL, Cell.WALL, Cell.WALL, Cell.WALL), 3, 3)); CollisionHandler handler = new CollisionHandler(check); Cell cell = handler.checkLevelAABB( new AABB(new Point(1.5, 1.5), new Point(2.5, 2.5)), new Point(0, 0)); <START> assertFalse(cell.getType() == Cell.EMPTY); <END> }</code><technical_language>assertNotEquals instead of == operator combined assertFalse, == work properly for non-objects. <testing</technical_language>

Target:
public void slightlyOccupiedAABBTest() { Level check = new Level(emptyPlayer, emptyUnit, new Grid<>(Arrays.asList( Cell.WALL, Cell.WALL, Cell.WALL, Cell.WALL, Cell.EMPTY, Cell.WALL, Cell.WALL, Cell.WALL, Cell.WALL), 3, 3)); CollisionHandler handler = new CollisionHandler(check); Cell cell = handler.checkLevelAABB( new AABB(new Point(1.5, 1.5), new Point(2.5, 2.5)), new Point(0, 0)); assertNotEquals(cell, Cell.EMPTY); }
Source:
<code>public String getColumnText(Object element, int columnIndex) { switch (columnIndex) { case 0: return getText(element); case 1: try { if (element instanceof StagingFolderEntry) { return null; } StagingEntry stagingEntry = (StagingEntry) element; Date modified; if (isStaged) { IFileRevision fileRevision = GitFileRevision.inIndex( stagingEntry.getRepository(), stagingEntry.getPath()); modified = new Date(fileRevision.getTimestamp()); } else { File file = new File(stagingEntry.getRepository() .getWorkTree(), stagingEntry.getPath()); modified = new Date(file.lastModified()); } <START> if (showRelativeDate) <END> return RelativeDateFormatter.format(modified); else return absoluteFormatter.format(modified); } catch (Exception e) { Activator.handleError(e.getCause().getMessage(), e.getCause(), false); return null; } default: return null; } }</code><technical_language>please brackets single line if/else too</technical_language>

Target:
public String getColumnText(Object element, int columnIndex) { switch (columnIndex) { case 0: return getText(element); case 1: try { if (element instanceof StagingFolderEntry) { return null; } StagingEntry stagingEntry = (StagingEntry) element; Date modified; if (isStaged) { IFileRevision fileRevision = GitFileRevision.inIndex( stagingEntry.getRepository(), stagingEntry.getPath()); modified = new Date(fileRevision.getTimestamp()); } else { File file = new File(stagingEntry.getRepository() .getWorkTree(), stagingEntry.getPath()); modified = new Date(file.lastModified()); } if (showRelativeDate) { return RelativeDateFormatter.format(modified); } else { return absoluteFormatter.format(modified); } } catch (Exception e) { Activator.handleError(e.getCause().getMessage(), e.getCause(), false); return null; } default: return null; } }
Source:
<code>public Optional<QosException> handle(Response response) { final Optional<QosException> result; switch (response.code()) { case 308: result = handle308(response); break; case 429: result = Optional.of(handle429(response)); break; case 503: result = Optional.of(handle503()); break; default: result = Optional.empty(); } <START> result.ifPresent(exception -> response.close()); <END> return result; }</code><technical_language>do this in code paths consumer response</technical_language>

Target:
public Optional<QosException> handle(Response response) { switch (response.code()) { case 308: return handle308(response); case 429: return Optional.of(handle429(response)); case 503: return Optional.of(handle503()); } return Optional.empty(); }
Source:
<code><START> public String toString() <END> { return "TaskStatusPlus{" + "id=" + id + ", type=" + type + ", createdTime=" + createdTime + ", queueInsertionTime=" + queueInsertionTime + ", state=" + state + ", duration=" + duration + ", location=" + location + ", dataSource=" + dataSource + "}"; }</code><technical_language>this toString errorMsg well</technical_language>

Target:
public String toString() { return "TaskStatusPlus{" + "id='" + id + '\'' + ", type='" + type + '\'' + ", createdTime=" + createdTime + ", queueInsertionTime=" + queueInsertionTime + ", state=" + state + ", duration=" + duration + ", location=" + location + ", dataSource='" + dataSource + '\'' + ", errorMsg='" + errorMsg + '\'' + '}'; }
Source:
<code>private void destroy(EntityRef ref) { long entityId = ref.getId(); entityStore.remove(entityId); entityManager.remove(entityId); <START> if (ref instanceof PojoEntityRef) { <END> ((PojoEntityRef) ref).invalidate(); } componentStore.remove(entityId); }</code><technical_language>get this instanceof somehow? generally invalidate EntityRef</technical_language>

Target:
private void destroy(EntityRef ref) { long entityId = ref.getId(); entityStore.remove(entityId); entityManager.remove(entityId); ref.invalidate(); componentStore.remove(entityId); }
Source:
<code>private void executeFileMove(FileActivity activity) throws IOException { SPath oldPath = activity.getOldPath(); IFile oldFile = oldPath.getFile(); SPath newPath = activity.getPath(); IFile newFile = newPath.getFile(); editorManager.moveFile(oldPath, newPath); oldFile.move(activity.getPath().getFullPath(), true); <START> newFile.setContents(new ByteArrayInputStream(activity.getContent()), true, true); <END> }</code><technical_language>getContent null if file moved</technical_language>

Target:
private void executeFileMove(FileActivity activity) throws IOException { SPath oldPath = activity.getOldPath(); IFile oldFile = oldPath.getFile(); SPath newPath = activity.getPath(); IFile newFile = newPath.getFile(); oldFile.move(activity.getPath().getFullPath(), true); byte[] content = activity.getContent(); if (content != null) { newFile.setContents(new ByteArrayInputStream(content), true, true); } editorManager.updateMapping(oldPath, newPath); }
Source:
<code>public <T> T tryReadingVault(Supplier<T> action) throws Retry.ActionFailedException { Optional<Span> optionalSpan = initSpan("read"); return optionalSpan.map(span -> { try (Scope ignored = tracer.activateSpan(span)) { try { return action.get(); } catch (RuntimeException e) { LOGGER.error("Exception during reading vault", e); span.setTag(TracingUtil.ERROR, true); span.setTag(TracingUtil.MESSAGE, e.getMessage()); metricService.incrementMetricCounter(MetricType.VAULT_READ_FAILED); throw new Retry.ActionFailedException(e.getMessage()); } } finally { span.finish(); } <START> }).orElseGet(action::get); <END> }</code><technical_language>This throw exception</technical_language>

Target:
public <T> T tryReadingVault(Supplier<T> action) throws Retry.ActionFailedException { return executeVaultOperationWithTrace(action, "read", MetricType.VAULT_READ_FAILED); }
Source:
<code>public static Object getPropertyByEntry(String entryId, String subKey) throws Exception { Object value; try { ConcurrentHashMap<String, Object> entryMap = entryIdToKalturaLiveEntryMap.get(entryId); value = entryMap.get(subKey); } catch (Exception e) { logger.error("(" + entryId + ") Failed to get value for key \"" + subKey + "\". " + e); <START> throw e; <END> } logger.debug("(" + entryId + ") Successfully got entry (map size:" + entryIdToKalturaLiveEntryMap.size() + ")"); return value; }</code><technical_language>check thow e crash media-server</technical_language>

Target:
public static Object getPropertyByEntry(String entryId, String subKey) throws Exception { Object value; try { ConcurrentHashMap<String, Object> entryMap = entryIdToKalturaLiveEntryMap.get(entryId); value = entryMap.get(subKey); } catch (Exception e) { logger.error("(" + entryId + ") Failed to get value for key \"" + subKey + "\". " + e); throw e; } logger.debug("(" + entryId + ") Successfully got entry subKey: (" + subKey + ")"); return value; }
Source:
<code>private RemoteCallback<TestScenarioModelContent> getModelSuccessCallback() { return new RemoteCallback<TestScenarioModelContent>() { @Override public void callback(final TestScenarioModelContent content) { if (versionRecordManager.getCurrentPath() == null) { return; } scenario = content.getScenario(); ifFixturesSizeZeroThenAddExecutionTrace(); dmo = oracleFactory.makeAsyncPackageDataModelOracle(versionRecordManager.getCurrentPath(), scenario, content.getDataModel()); resetEditorPages(content.getOverview()); addImportsTab(importsWidget); addPage(kiePage); <START> addPage(auditPage); <END> redraw(); view.hideBusyIndicator(); } }; }</code><technical_language>cover some tests</technical_language>

Target:
private RemoteCallback<TestScenarioModelContent> getModelSuccessCallback() { return new RemoteCallback<TestScenarioModelContent>() { @Override public void callback(final TestScenarioModelContent content) { if (versionRecordManager.getCurrentPath() == null) { return; } scenario = content.getScenario(); ifFixturesSizeZeroThenAddExecutionTrace(); dmo = oracleFactory.makeAsyncPackageDataModelOracle(versionRecordManager.getCurrentPath(), scenario, content.getDataModel()); resetEditorPages(content.getOverview()); addImportsTab(importsWidget); addPage(settingsPage); addPage(auditPage); redraw(); view.hideBusyIndicator(); } }; }