Skip to content

Commit

Permalink
errorprone :: MissingOverride & RedundantOverride (#772)
Browse files Browse the repository at this point in the history
  • Loading branch information
sambish5 committed May 10, 2024
1 parent 58d57d7 commit 65add6d
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 5 deletions.
1 change: 1 addition & 0 deletions src/main/java/emissary/core/TransformHistory.java
Expand Up @@ -209,6 +209,7 @@ public boolean wasCoordinated() {
return coordinated;
}

@Override
public String toString() {
String start;
if (wasCoordinated()) {
Expand Down
Expand Up @@ -29,6 +29,7 @@ public AllMaxTime(String name, String place, String timeLimit, String threshold)
* @param placeAgentStats the stats of a place that is currently processing
* @return true if any places in mobile agents are over the configured time limit, false otherwise
*/
@Override
protected boolean overTimeLimit(Collection<Protocol.PlaceAgentStats> placeAgentStats) {
long minTimeInPlace = placeAgentStats.stream().mapToLong(Protocol.PlaceAgentStats::getMinTimeInPlace).min().orElse(0);
logger.debug("Testing timeLimit for place={}, minTime={}, timeLimit={}", place, minTimeInPlace, timeLimit);
Expand Down
Expand Up @@ -29,6 +29,7 @@ public AnyMaxTime(String name, String place, String timeLimit, String threshold)
* @param placeAgentStats the stats of a place that is currently processing
* @return true if any places in mobile agents are over the configured time limit, false otherwise
*/
@Override
protected boolean overTimeLimit(Collection<Protocol.PlaceAgentStats> placeAgentStats) {
long maxTimeInPlace = placeAgentStats.stream().mapToLong(Protocol.PlaceAgentStats::getMaxTimeInPlace).max().orElse(0);
logger.debug("Testing timeLimit for place={}, maxTime={}, timeLimit={}", place, maxTimeInPlace, timeLimit);
Expand Down
1 change: 1 addition & 0 deletions src/main/java/emissary/place/ServiceProviderPlace.java
Expand Up @@ -1121,6 +1121,7 @@ protected IBaseDataObject getTLD() {
return null;
}

@Override
public boolean isDenied(String s) {
return denyList.contains(s);
}
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/emissary/util/shell/Executrix.java
Expand Up @@ -1330,6 +1330,7 @@ public SbExecuteConfig(String[] cmd, byte[] data, StringBuilder out, StringBuild
this.out = out;
}

@Override
public ProcessReader getStdOutProcessReader(Process p) {
return out == null ? super.getStdOutProcessReader(p) : new ReadOutputBuffer(p.getInputStream(), out);
}
Expand All @@ -1345,6 +1346,7 @@ public BaosExecuteConfig(String[] cmd, byte[] data, ByteArrayOutputStream out, S
this.out = out;
}

@Override
public ProcessReader getStdOutProcessReader(Process p) {
return out == null ? super.getStdOutProcessReader(p) : new ReadBinaryOutputBuffer(p.getInputStream(), out);
}
Expand Down
1 change: 1 addition & 0 deletions src/main/java/emissary/util/shell/ProcessReader.java
Expand Up @@ -39,6 +39,7 @@ protected final void applyLogContextMap() {
* Wrapper method to ensure that the {@link #applyLogContextMap()} method is always invoked before executing the core
* functionality of ProcessReader subclasses
*/
@Override
public void run() {
applyLogContextMap();
runImpl();
Expand Down
5 changes: 0 additions & 5 deletions src/test/java/emissary/pickup/file/FilePickUpClientTest.java
Expand Up @@ -151,10 +151,5 @@ protected String caseIdHook(String initialCaseId, String sessionname, String fil
return super.caseIdHook(initialCaseId, sessionname, fileName, metadata);
}
}

@Override
protected String createFilename(String filePath, String prefix) {
return super.createFilename(filePath, prefix);
}
}
}

0 comments on commit 65add6d

Please sign in to comment.