Skip to content

[MINOR] Switch to FileIO for InputFormat#1526

Merged
rdblue merged 1 commit into
apache:masterfrom
holdenk:switch-to-fileIOforInputFormat
Sep 29, 2020
Merged

[MINOR] Switch to FileIO for InputFormat#1526
rdblue merged 1 commit into
apache:masterfrom
holdenk:switch-to-fileIOforInputFormat

Conversation

@holdenk

@holdenk holdenk commented Sep 28, 2020

Copy link
Copy Markdown
Contributor

There was a TODO saying to switch to FileIO from directly accessing the HadoopInputFile class.

@rdblue rdblue merged commit ab0b5a6 into apache:master Sep 29, 2020
@rdblue

rdblue commented Sep 29, 2020

Copy link
Copy Markdown
Contributor

Looks good, and helps unblock #1497. Thanks @holdenk!

// For now IcebergInputFormat does its own split planning and does not accept FileSplit instances
CombinedScanTask task = ((IcebergSplit) split).task();
this.context = newContext;
this.fileIO = new HadoopFileIO(this.context.getConfiguration());

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: we use this. to distinguish instance fields when setting them, but there's no need when accessing them.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks, I'll keep that in mind :)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good to know! Do we document these style preferences anywhere (using this, when we use the term project vs select, etc)? @rdblue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants