AmatyaAvadhanula commented on code in PR #16362:
URL: https://github.com/apache/druid/pull/16362#discussion_r1585794842
##########
indexing-service/src/main/java/org/apache/druid/indexing/common/task/KillUnusedSegmentsTask.java:
##########
@@ -341,6 +342,15 @@ private NavigableMap<DateTime, List<TaskLock>>
getNonRevokedTaskLockMap(TaskActi
return taskLockMap;
}
+ @Override
+ public boolean isReady(TaskActionClient taskActionClient) throws Exception
+ {
+ if (markAsUnused) {
+ return super.isReady(taskActionClient);
+ }
+ return super.isReady(taskActionClient,
getContextValue(Tasks.TASK_LOCK_TYPE, TaskLockType.SHARED));
Review Comment:
@abhishekrb19 Having concurrent kill tasks definitely doesn't seem ideal
from a resource perspective.
When using a limit on the number of segments killed, I do not think we can
guarantee idempotence either.
We should definitely use EXCLUSIVE as the default and REPLACE as the
preferred concurrent lock.
--
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]