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

Daily updates - land data #78

Open
agstephens opened this issue Mar 29, 2021 · 0 comments
Open

Daily updates - land data #78

agstephens opened this issue Mar 29, 2021 · 0 comments

Comments

@agstephens
Copy link
Collaborator

agstephens commented Mar 29, 2021

@jhaigh0 As discussed with Simon, here is our plan for running daily updates:

  1. Outline:
  • we want a single script that will:
    • find the latest cdmlite daily update files
    • attempt to process each file:
      1. Restructure file to PSV under: /work/scratch...
      2. Generate SQL command to load the new file
      3. Execute the SQL command
      4. Remove the input file(s) under: /work/scratch...
  1. Data locations and proposed workflow:
  • data will be found in:
    • /gws/nopw/j04/c3s311a_lot2/data/level2/land/r202102/daily_updates/cdm_lite/
    • In the subdirectory incoming/
  • for each file we process, we will:
    1. Move it to processing/
    2. Attempt to process it (as outlined above)
    3. If any part of the process fails, move it failed/ and log/email result
    4. If it succeeds, move it to complete/ and log/email result
  1. Script details:
  • the script can be bash or python
  • it should be called something like: ./scripts/land/run-daily-update-cdmlite.(py|sh)
  • it will need to use the settings file to get the location of the .../daily_updates/cdm_lite/ directory for a given release.
  1. Once it is all working:
  • we will schedule it to run once per day - probably submitted to a LOTUS node, but kicked off by the cron server.
@jhaigh0 jhaigh0 removed their assignment Oct 26, 2022
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

No branches or pull requests

2 participants