github-advanced-security[bot] commented on code in PR #17509:
URL: https://github.com/apache/druid/pull/17509#discussion_r1854552927
##########
indexing-service/src/main/java/org/apache/druid/indexing/common/actions/SegmentTransactionalInsertAction.java:
##########
@@ -212,7 +217,20 @@
checkWithSegmentLock();
}
}
-
+ String dataSourceToInsert =
segments.stream().findFirst().get().getDataSource();
+ if (task instanceof SeekableStreamIndexTask) {
+ SeekableStreamIndexTask seekableStreamIndexTask =
(SeekableStreamIndexTask) task;
+ if
(!toolbox.getSupervisorManager().canPublishSegments(dataSourceToInsert,
seekableStreamIndexTask.getIOConfig().getTaskGroupId(), task.getId())) {
+ log.warn("Streaming task [%s] is not currently publishable.",
task.getId());
+ throw DruidException
+ .forPersona(DruidException.Persona.DEVELOPER)
+ .ofCategory(DruidException.Category.SERVICE_UNAVAILABLE)
+ .build("Cannot append segments to [%s] right now." +
+ "There might be another task waiting to publish its
segments. Check the overlord logs for details.",
Review Comment:
## Missing space in string literal
This string appears to be missing a space after 'now.'.
[Show more
details](https://github.com/apache/druid/security/code-scanning/8473)
--
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]