Skip to content

Commit

Permalink
ORC-1591: Lower log level from INFO to DEBUG in `*ReaderImpl/WriterIm…
Browse files Browse the repository at this point in the history
…pl/PhysicalFsWriter`

### What changes were proposed in this pull request?

This PR aims to lower several log message's level from INFO to DEBUG.

### Why are the changes needed?

To reduce verbose INFO level messages.

### How was this patch tested?

Manual test because these are log-level changes.

### Was this patch authored or co-authored using generative AI tooling?

No.

Closes #1754 from dongjoon-hyun/ORC-1591.

Authored-by: Dongjoon Hyun <[email protected]>
Signed-off-by: Dongjoon Hyun <[email protected]>
  • Loading branch information
dongjoon-hyun committed Jan 16, 2024
1 parent 915c267 commit b126033
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions java/core/src/java/org/apache/orc/impl/PhysicalFsWriter.java
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ public PhysicalFsWriter(FileSystem fs,
this(fs.create(path, opts.getOverwrite(), HDFS_BUFFER_SIZE,
fs.getDefaultReplication(path), opts.getBlockSize()), opts, encryption);
this.path = path;
LOG.info("ORC writer created for path: {} with stripeSize: {} blockSize: {}" +
LOG.debug("ORC writer created for path: {} with stripeSize: {} blockSize: {}" +
" compression: {}", path, opts.getStripeSize(), blockSize, compress);
}

Expand Down Expand Up @@ -509,7 +509,7 @@ public void appendRawStripe(ByteBuffer buffer,
if (length < blockSize && length > availBlockSpace &&
addBlockPadding) {
byte[] pad = new byte[(int) Math.min(HDFS_BUFFER_SIZE, availBlockSpace)];
LOG.info("Padding ORC by {} bytes while merging", availBlockSpace);
LOG.debug("Padding ORC by {} bytes while merging", availBlockSpace);
start += availBlockSpace;
while (availBlockSpace > 0) {
int writeLen = (int) Math.min(availBlockSpace, pad.length);
Expand Down
2 changes: 1 addition & 1 deletion java/core/src/java/org/apache/orc/impl/ReaderImpl.java
Original file line number Diff line number Diff line change
Expand Up @@ -891,7 +891,7 @@ public RecordReader rows() throws IOException {

@Override
public RecordReader rows(Options options) throws IOException {
LOG.info("Reading ORC rows from " + path + " with " + options);
LOG.debug("Reading ORC rows from " + path + " with " + options);
return new RecordReaderImpl(this, options);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ protected RecordReaderImpl(ReaderImpl fileReader,
OrcFile.WriterVersion writerVersion = fileReader.getWriterVersion();
SchemaEvolution evolution;
if (options.getSchema() == null) {
LOG.info("Reader schema not provided -- using file schema " +
LOG.debug("Reader schema not provided -- using file schema " +
fileReader.getSchema());
evolution = new SchemaEvolution(fileReader.getSchema(), null, options);
} else {
Expand Down
2 changes: 1 addition & 1 deletion java/core/src/java/org/apache/orc/impl/WriterImpl.java
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ public WriterImpl(FileSystem fs,

treeWriter = TreeWriter.Factory.create(schema, null, new StreamFactory());

LOG.info("ORC writer created for path: {} with stripeSize: {} options: {}",
LOG.debug("ORC writer created for path: {} with stripeSize: {} options: {}",
path, stripeSize, unencryptedOptions);
}

Expand Down

0 comments on commit b126033

Please sign in to comment.