File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
client/src/main/java/org/asynchttpclient/request/body/generator Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change 16
16
import java .util .concurrent .ArrayBlockingQueue ;
17
17
import java .util .concurrent .BlockingQueue ;
18
18
19
- public final class BlockingQueueFeedableBodyGenerator extends QueueBasedFeedableBodyGenerator <BlockingQueue <BodyChunk >> {
19
+ public final class BoundedQueueFeedableBodyGenerator extends QueueBasedFeedableBodyGenerator <BlockingQueue <BodyChunk >> {
20
20
21
- public BlockingQueueFeedableBodyGenerator (int capacity ) {
21
+ public BoundedQueueFeedableBodyGenerator (int capacity ) {
22
22
super (new ArrayBlockingQueue <>(capacity , true ));
23
23
}
24
24
25
25
@ Override
26
26
protected boolean offer (BodyChunk chunk ) throws InterruptedException {
27
- queue .put (chunk );
28
- return true ;
27
+ return queue .offer (chunk );
29
28
}
30
29
}
You can’t perform that action at this time.
0 commit comments