-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add run_id CLI argument and Transformer attribute
Why these changes are being introduced: As we move into Transmogrifier writing to a parquet dataset, one important bit of information it will need is the concept of a "run id". This correlates directly to an "Execution UUID" that every StepFunction invocation produces. This identifier is then used when writing the records to the parquet dataset, allowing for quick and easy access to records associated with that identifier. There is a small many-to-one relationship that makes naming a bit awkward: each StepFunction invocation may run Transmogrifier multiple times (e.g. multiple input files). Each time it invokes Transmogrifier, the same "run_id" would be passed. This effectively groups the outputs of all Transmogrifier invocations in the same location in the parquet dataset. The language of this new "run_id" in Transmogrifier is intentionally somewhat high level, indicating it's just an identifier to associate with that invocation of the run. How this addresses that need: * Adds new CLI argument -r / --run-id * Transformer gets new attribute 'run_id' * Transformer mints a UUID of a run id is not passed, making the change backwards compatible and inconsequential if a run id is not passed Side effects of this change: * Going forward, invocations of Transmogrifier can use the run id as part of the parquet record writing. Until then, it has no effect. Relevant ticket(s): * https://mitlibraries.atlassian.net/browse/TIMX-403
- Loading branch information
Showing
6 changed files
with
134 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters