Improve performance reading from network.
Improve performance reading from network.

data_thread reads XML 1023 bytes at a time, which is silly and
inefficient. Instead, create a buffer that doubles in size as necessary
and has a more reasonable initial buffer size.

When we get gzip content, start with a buffer size larger than our
gzipped contents, since we will probably need that anyway.

torkelsson/monitor-core,fastly/monitor-core,torkelsson/monitor-core,lawrencewu/monitor-core,NoodlesNZ/monitor-core,mjzhou/monitor-core,sdgdsffdsfff/monitor-core,fastly/monitor-core,sdgdsffdsfff/monitor-core,fastly/monitor-core,fastly/monitor-core,phreakocious/monitor-core,phreakocious/monitor-core,mjzhou/monitor-core,phreakocious/monitor-core,ganglia/monitor-core,mjzhou/monitor-core,fastly/monitor-core,torkelsson/monitor-core,NoodlesNZ/monitor-core,mjzhou/monitor-core,ganglia/monitor-core,phreakocious/monitor-core,mjzhou/monitor-core,sdgdsffdsfff/monitor-core,sdgdsffdsfff/monitor-core,sdgdsffdsfff/monitor-core,phreakocious/monitor-core,sdgdsffdsfff/monitor-core,mjzhou/monitor-core,lawrencewu/monitor-core,NoodlesNZ/monitor-core,torkelsson/monitor-core,lawrencewu/monitor-core,NoodlesNZ/monitor-core,ganglia/monitor-core,phreakocious/monitor-core,fastly/monitor-core,mjzhou/monitor-core,ganglia/monitor-core,ganglia/monitor-core,lawrencewu/monitor-core,torkelsson/monitor-core,ganglia/monitor-core,lawrencewu/monitor-core,torkelsson/monitor-core,torkelsson/monitor-core,ganglia/monitor-core,phreakocious/monitor-core,lawrencewu/monitor-core,ganglia/monitor-core,fastly/monitor-core,NoodlesNZ/monitor-core,NoodlesNZ/monitor-core,sdgdsffdsfff/monitor-core,lawrencewu/monitor-core,NoodlesNZ/monitor-core