Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
amishas157 committed Nov 26, 2024
1 parent 323425d commit 1efbbe7
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions cmd/export_ledger_entry_changes.go
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ func exportTransformedData(
transformedOutput map[string][]interface{},
cloudCredentials, cloudStorageBucket, cloudProvider string,
extra map[string]string,
WriteParquet bool) error {
writeParquet bool) error {

for resource, output := range transformedOutput {
// Filenames are typically exclusive of end point. This processor
Expand All @@ -305,7 +305,7 @@ func exportTransformedData(
return err
}

if WriteParquet {
if writeParquet {
switch v := o.(type) {
case transform.AccountOutput:
transformedResource = append(transformedResource, v)
Expand Down Expand Up @@ -354,7 +354,7 @@ func exportTransformedData(

MaybeUpload(cloudCredentials, cloudStorageBucket, cloudProvider, path)

if !skip && WriteParquet {
if !skip && writeParquet {
WriteParquet(transformedResource, parquetPath, parquetSchema)
MaybeUpload(cloudCredentials, cloudStorageBucket, cloudProvider, parquetPath)
}
Expand Down
8 changes: 4 additions & 4 deletions internal/utils/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -409,7 +409,7 @@ func MustFlags(flags *pflag.FlagSet, logger *EtlLogger) FlagValues {
logger.Fatal("could not get cloud provider: ", err)
}

writeParquet, err := flags.GetBool("write-parquet")
WriteParquet, err := flags.GetBool("write-parquet")
if err != nil {
logger.Fatal("could not get write-parquet flag: ", err)
}
Expand All @@ -433,7 +433,7 @@ func MustFlags(flags *pflag.FlagSet, logger *EtlLogger) FlagValues {
Bucket: bucket,
Credentials: credentials,
Provider: provider,
WriteParquet: writeParquet,
WriteParquet: WriteParquet,
}
}

Expand Down Expand Up @@ -513,7 +513,7 @@ func MustCommonFlags(flags *pflag.FlagSet, logger *EtlLogger) CommonFlagValues {
logger.Fatal("could not get retry-wait uint32: ", err)
}

writeParquet, err := flags.GetBool("write-parquet")
WriteParquet, err := flags.GetBool("write-parquet")
if err != nil {
logger.Fatal("could not get write-parquet flag: ", err)
}
Expand All @@ -530,7 +530,7 @@ func MustCommonFlags(flags *pflag.FlagSet, logger *EtlLogger) CommonFlagValues {
NumWorkers: numWorkers,
RetryLimit: retryLimit,
RetryWait: retryWait,
WriteParquet: writeParquet,
WriteParquet: WriteParquet,
}
}

Expand Down

0 comments on commit 1efbbe7

Please sign in to comment.