Skip to content

Commit

Permalink
ALS-6511: Add log message for avro file locaton
Browse files Browse the repository at this point in the history
  • Loading branch information
ramari16 committed Jul 22, 2024
1 parent d149826 commit bd3a945
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
import org.apache.avro.generic.GenericDatumWriter;
import org.apache.avro.generic.GenericRecord;
import org.apache.avro.io.DatumWriter;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import java.io.File;
import java.io.IOException;
Expand All @@ -16,6 +18,8 @@

public class PfbWriter implements ResultWriter {

private Logger log = LoggerFactory.getLogger(PfbWriter.class);

private final Schema metadataSchema;
private final Schema nodeSchema;
private SchemaBuilder.FieldAssembler<Schema> entityFieldAssembler;
Expand Down Expand Up @@ -65,6 +69,7 @@ public void writeHeader(String[] data) {
DatumWriter<GenericRecord> datumWriter = new GenericDatumWriter<GenericRecord>(entitySchema);
dataFileWriter = new DataFileWriter<GenericRecord>(datumWriter);
try {
log.info("Creating temp avro file at " + file.getAbsoluteFile());
dataFileWriter.create(entitySchema, file);
} catch (IOException e) {
throw new UncheckedIOException(e);
Expand Down

0 comments on commit bd3a945

Please sign in to comment.