Skip to contents

Writes a data frame to a versioned Parquet file and uploads it to cloud storage.

Usage

upload_parquet_to_cloud(
  data,
  prefix,
  provider,
  options,
  compression = "lz4",
  compression_level = 12,
  bucket_name = NULL
)

Arguments

data

A data frame containing the data to be uploaded.

prefix

A character string specifying the file prefix path.

provider

A character string specifying the cloud storage provider key.

options

A named list of cloud storage provider options.

compression

A character string specifying compression type. Default is "lz4".

compression_level

An integer specifying compression level. Default is 12.

bucket_name

Optional character string specifying the GCS bucket name. If provided, overrides the bucket in options. If NULL (default), uses the bucket defined in options.

Value

Invisible NULL (called for side effects).

Examples

if (FALSE) { # \dontrun{
upload_parquet_to_cloud(
  data = survey_data,
  prefix = "raw-data/survey-data",
  provider = conf$storage$google$key,
  options = conf$storage$google$options
)
} # }