[ 
https://issues.apache.org/jira/browse/HTTPCLIENT-1740?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Oleg Kalnichevski resolved HTTPCLIENT-1740.
-------------------------------------------
    Resolution: Not A Problem

No, there is not. 

Please, in the future post your questions to the user list. 

Oleg

> Is there a way to change the Max Response Size via configuration property?
> --------------------------------------------------------------------------
>
>                 Key: HTTPCLIENT-1740
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1740
>             Project: HttpComponents HttpClient
>          Issue Type: Wish
>          Components: HttpClient
>            Reporter: Tenji Shen
>              Labels: features
>
> I know that there is one way to achieve, get the data as InputStream and 
> decide how many bytes I want to read myself. Just like:
> in = method.getResponseBodyAsStream();
> out = new ByteArrayOutputStream(READ_BUFFER_SIZE);
> while ((len = in.read(buff)) != -1 && byteCount <= RESPONSE_SIZE_LIMIT) {
>     byteCount += len;
>     out.write(buff, 0, len);
> }
> if (byteCount >= RESPONSE_SIZE_LIMIT) {
>     throw new IOException(
>             "Size limited exceeded reading from HTTP input stream");
> }
> But I was wondering if there is a possible way to limit response size via 
> configuration property, thanks for answering.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to