Skip to content

Commit

Permalink
fix jsonpath renaming, apache#3315
Browse files Browse the repository at this point in the history
  • Loading branch information
hansva committed Nov 15, 2023
1 parent ff03096 commit b755656
Showing 1 changed file with 15 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ public GoogleSheetsInputMeta() {
super();
inputFields = new ArrayList<>();
}
@HopMetadataProperty(key="jsonCrendentialPath", injectionGroupKey = "SHEET" ,isExcludedFromInjection = true)
private String oldJsonCredentialPath;

@HopMetadataProperty(key="jsonCredentialPath", injectionGroupKey = "SHEET")
private String jsonCredentialPath;
Expand Down Expand Up @@ -88,6 +90,10 @@ public void setDefault() {
}

public String getJsonCredentialPath() {
if(getOldJsonCredentialPath() != null && this.jsonCredentialPath == null){
this.jsonCredentialPath = getOldJsonCredentialPath();
setOldJsonCredentialPath(null);
}
return this.jsonCredentialPath == null ? "" : this.jsonCredentialPath;
}

Expand Down Expand Up @@ -150,6 +156,15 @@ public void setAppName(String appName) {
this.appName = appName;
}


public String getOldJsonCredentialPath() {
return oldJsonCredentialPath;
}

public void setOldJsonCredentialPath(String oldJsonCredentialPath) {
this.oldJsonCredentialPath = oldJsonCredentialPath;
}

@Override
public void getFields(
IRowMeta rowMeta,
Expand Down

0 comments on commit b755656

Please sign in to comment.