github-advanced-security[bot] commented on code in PR #19926: URL: https://github.com/apache/druid/pull/19926#discussion_r3738837956
########## indexing-service/src/test/java/org/apache/druid/indexing/common/task/batch/parallel/AbstractParallelIndexSupervisorTaskTest.java: ########## @@ -167,11 +165,27 @@ private static final Logger LOG = new Logger(AbstractParallelIndexSupervisorTaskTest.class); - @Rule - public final TemporaryFolder temporaryFolder = new TemporaryFolder(); + protected final File temporaryFolder = FileUtils.createTempDir(); Review Comment: ## CodeQL / Field masks field in super class This field shadows another field called [temporaryFolder](1) in a superclass. [Show more details](https://github.com/apache/druid/security/code-scanning/11741) ########## indexing-service/src/test/java/org/apache/druid/indexing/common/task/batch/parallel/RangePartitionMultiPhaseParallelIndexingTest.java: ########## @@ -452,18 +450,18 @@ DimensionRangeShardSpec shardSpec = (DimensionRangeShardSpec) segment.getShardSpec(); StringTuple start = shardSpec.getStartTuple(); StringTuple end = shardSpec.getEndTuple(); - Assert.assertTrue(shardSpec.toString(), start != null || end != null); + Assertions.assertTrue(start != null || end != null, shardSpec.toString()); for (StringTuple value : values) { if (start != null) { - MatcherAssert.assertThat(value.compareTo(start), Matchers.greaterThanOrEqualTo(0)); + Assertions.assertTrue(value.compareTo(start) >= 0); Review Comment: ## CodeQL / Dereferenced variable may be null Variable [value](1) may be null at this access as suggested by [this](2) null guard. [Show more details](https://github.com/apache/druid/security/code-scanning/11742) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
