Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(jobs): accept yaml configuration data #1463

Merged
merged 4 commits into from
Oct 31, 2024

Conversation

sbliven
Copy link
Contributor

@sbliven sbliven commented Oct 25, 2024

Description

Implement #1120 by using a yaml parser in place of the JSON parser for the jobconfig file. Note that JSON files are also valid YAML, so this change is backwards-compatible to existing json configuration files.

Motivation

YAML is

Changes:

  • Add yaml support for configuring jobs (Parse config files as YAML #1120)
  • The job configuration file defaults to "./jobConfig.yaml" but can also be set to a json file or other extension using the JOB_CONFIGURATION_FILE env variable.

Tests included

  • Included for each change/fix?
  • Passing?

Documentation

  • swagger documentation updated (required for API changes) (N/A)
  • official documentation updated

official documentation info

Examples have been updated from json to yaml in the documentation#56

Example files are deliberately not converted in this commit to test
json parsing with js-yaml
@sbliven sbliven self-assigned this Oct 25, 2024
@sbliven sbliven changed the base branch from master to release-jobs October 25, 2024 16:11
JSON is still accepted as well, but documentation will be updated
to use YAML.

Move jobConfig.example.yaml to the top-level for better visibility.
@sbliven sbliven changed the title [WIP] feat: accept yaml configuration data feat(jobs): accept yaml configuration data Oct 29, 2024
sbliven added a commit to sbliven/scicat-backend-next that referenced this pull request Oct 31, 2024
- Update docstring
- update jobConfig.example.json. Changes will need to be converted to
  yaml following the merge of SciCatProject#1463
Copy link

@despadam despadam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good 👍

@sbliven sbliven merged commit b1be267 into SciCatProject:release-jobs Oct 31, 2024
7 checks passed
@sbliven sbliven deleted the yamlconfig branch October 31, 2024 13:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants