FileTransform FileTransform

type: "io.kestra.plugin.scripts.nashorn.FileTransform"

Transform ion format file from kestra with a nashorn (javascript) script.

# Examples

id: "file_transform"
type: "io.kestra.plugin.scripts.nashorn.FileTransform"
from: "{{ outputs['avro-to-gcs'] }}"
script: |
  logger.info('row: {}', row)

  if (row['name'] === 'richard') {
    row = null
  } else {
    row['email'] = row['name'] + '@kestra.io')
  }

# Properties

# concurrent

  • Type: integer
  • Dynamic:
  • Required:
  • Minimum: >= 2

Number of concurrent parallels transform

Take care that the order is not respected if you use parallelism

# from

  • Type: string
  • Dynamic: ✔️
  • Required: ✔️

Source file URI

The file must an ion file generated by kestra

# script

  • Type: string
  • Dynamic: ✔️
  • Required:

A full script

# Outputs

# uri

  • Type: string

URI of a temporary result file

The file will be serialized as ion file.