mirror of
https://github.com/apache/druid.git
synced 2025-02-17 07:25:02 +00:00
fix FileUtils performance regression due to FilterOutputStream (#8024)
This commit is contained in:
parent
e6ba258197
commit
6760505a7e
@ -242,6 +242,14 @@ public class FileUtils
|
|||||||
{
|
{
|
||||||
return new FilterOutputStream(out)
|
return new FilterOutputStream(out)
|
||||||
{
|
{
|
||||||
|
// Default implementation of this method in FilterOutputStream converts single write operation to
|
||||||
|
// multiple write operations of 1 byte each, which is terribly inefficient.
|
||||||
|
@Override
|
||||||
|
public void write(byte b[], int off, int len) throws IOException
|
||||||
|
{
|
||||||
|
out.write(b, off, len);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void close()
|
public void close()
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user