hadoop-common-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Aaron Fabbri (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HADOOP-11684) S3a to use thread pool that blocks clients
Date Thu, 29 Oct 2015 00:49:28 GMT

    [ https://issues.apache.org/jira/browse/HADOOP-11684?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14979575#comment-14979575

Aaron Fabbri commented on HADOOP-11684:

Thanks for review [~eddyxu].  I will fix the style issues you mention.

On the final point: Using synchronization instead of sleeps to block tasks from finishing..
I like the idea.   I can implement it, but detecting whether or not the final submit() blocks
will still be subject to sleep race condition.

That is, I can guarantee first n threads will not finish before I've determined that the n+1'th
thread has blocked (i.e. latch instead of sleep), but determining how long to wait until that
n+1'th threadPool.submit() has "blocked" is still a race.  I can't distinguish between our
thread being runnable but not scheduled and actually blocking from Java, AFAIK.

Three options:
1. I fix this test (which doesn't run by default) to be less-but-still-racy.
2. I fix all style etc. issues, but leave sleep-based implementation.
3. I remove the unit test.  It has served to show the amount of testing done on the patch,
and may be a little too fancy anyways.

> S3a to use thread pool that blocks clients
> ------------------------------------------
>                 Key: HADOOP-11684
>                 URL: https://issues.apache.org/jira/browse/HADOOP-11684
>             Project: Hadoop Common
>          Issue Type: Sub-task
>          Components: fs/s3
>    Affects Versions: 2.7.0
>            Reporter: Thomas Demoor
>            Assignee: Thomas Demoor
>         Attachments: HADOOP-11684-001.patch, HADOOP-11684-002.patch, HADOOP-11684-003.patch,
> Currently, if fs.s3a.max.total.tasks are queued and another (part)upload wants to start,
a RejectedExecutionException is thrown. 
> We should use a threadpool that blocks clients, nicely throtthling them, rather than
throwing an exception. F.i. something similar to https://github.com/apache/incubator-s4/blob/master/subprojects/s4-comm/src/main/java/org/apache/s4/comm/staging/BlockingThreadPoolExecutorService.java

This message was sent by Atlassian JIRA

View raw message