Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[hive-2.3.9]Set empty yosegi config if read column is not present. #74

Open
wants to merge 1 commit into
base: hive-2.3.9
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -299,14 +299,6 @@
</build>

<repositories>
<repository>
<id>hdp</id>
<url> http://repo.hortonworks.com/content/repositories/releases</url>
<name>HDP</name>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
<repository>
<id>pentaho</id>
<url>https://repo.orl.eng.hitachivantara.com/artifactory/pnt-mvn/</url>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ public HiveReaderSetting( final FileSplit split, final JobConf job ) {
* Create the setting of the column to be read by Yosegi.
*/
public String createReadColumnNames( final String readColumnNames ) {
if ( readColumnNames == null || readColumnNames.isEmpty() ) {
if ( readColumnNames == null ) {
return null;
}
StringBuilder jsonStringBuilder = new StringBuilder();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public void T_createReadColumnNames_1(){
public void T_createReadColumnNames_2(){
HiveReaderSetting setting = new HiveReaderSetting( null , null , false , false , false );
String readColumnJson = setting.createReadColumnNames( "" );
assertEquals( readColumnJson , null );
assertEquals( readColumnJson , "[]" );
}

@Test
Expand Down