Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions recipes/fdb/5.19/environments.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -94,3 +94,23 @@ fdb:
- ECCODES_ECKIT_GEO: "1"
prepend_path:
- PATH: "$@mount@/venvs/fdb/bin/"
archive:
link: roots
uenv:
prefix_paths:
LD_LIBRARY_PATH: [lib, lib64]
env_vars:
set:
- FDB_HOME: "$@view_path@"
- FDB5_HOME: "$@view_path@"
- ECKIT_HOME: "$@view_path@"
- GRIB_DEFINITION_PATH: "$@mount@/data/share/eccodes-cosmo-mars/definitions:\
$@mount@/venvs/fdb/share/eccodes-cosmo-resources/definitions:\
$@mount@/env/fdb/share/eccodes/definitions"
# NOTE: this assumes that the fdb config names match the view names
- FDB5_CONFIG_FILE: "$@mount@/meta/recipe/meta/private/fdb_config/$@view_name@.yaml"
- FDB_ENABLE_GRIBJUMP: "1"
- AUTO_LOAD_PLUGINS: "1"
- ECCODES_ECKIT_GEO: "1"
prepend_path:
- PATH: "$@mount@/venvs/fdb/bin/"
107 changes: 107 additions & 0 deletions recipes/fdb/5.19/meta/private/fdb_config/archive.schema
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@

# * Format of the rules is:

# [a1, a2, a3 ...[b1, b2, b3... [c1, c2, c3...]]]

# - The first level (a) defines which attributes are used to name the top level directory
# - The second level (b) defines which attributes are used to name the data files
# - The third level (c) defines which attributes are used as index keys

# * Rules can be grouped

# [a1, a2, a3 ...
# [b1, b2, b3... [c1, c2, c3...]]
# [B1, B2, B3... [C1, C2, C3...]]
# ]

# * A list of values can be given for an attribute
# [ ..., stream=enfo/efov, ... ]
# This will be used when matching rules.

# * Attributes can be typed
# Globally, at the begining of this file:

# refdate: Date;

# or in the context of a rule:
# [type=cl, ... [date:ClimateMonth, ...]]

# Typing attributes is done when the user's requests or the GRIB values need to be modified before directories, files and indexes are created. For example, ClimateMonth will transform 2010-04-01 to 'may' internally.

# * Attributes can be optional
# [ step, levelist?, param ]
# They will be replaced internally by an empty value. It is also posiible to provide a default subtitution value: e.g. [domain?g] will consider the domain to be 'g' if missing.

# * Attributes can be removed:
# [grid-]
# This is useful to remove attributes present in the GRIB that should not be ignored

# * Rules are matched:

# - If the attributes are present in the GRIB/Request, or marked optional or ignored
# - If a list of possible value is provided, one of them must match, for example
# [ class, expver, stream=enfo/efov, date, time, domain ]
# will match either stream=enfo or stream=efov, all other attributes will be matched if they exist in the GRIB or user's request

# * On archive:
# - Attributes are extracted from the GRIB (namespace 'mars'), possibly modified by the attribute type
# - Only the first rule is used, so order is important
# - All GRIB attributes must be used by the rules, otherwise an error is raised

# * On retrieve:
# - Attributes are extracted from the user's request, possibly modified by the attribute type (e.g. for handling of U/V)
# - All the matching rules are considered
# - Only attributes listed in the rules are used to extract values from the user's request


# Default types

param: Param;
step: Step;
date: Date;
hdate: Date;
refdate: Date;
latitude: Double;
longitude: Double;
level: Double;
levelist: Double;
grid: Grid;
expver: Expver;

time: Time;
fcmonth: Integer;

number: Integer;
frequency: Integer;
direction: Integer;
channel: Integer;

instrument: Integer;
ident: Integer;

diagnostic: Integer;
iteration: Integer;
system: Integer;
method: Integer;

# ???????

# reference: Integer;
# fcperiod: Integer;

# opttime: Integer;
# leadtime: Integer;

# quantile: ??????
# range: ??????

# band: Integer;


########################################################
# These rules must be first, otherwise fields of These
# classes will be index with the default rule for oper #expver?, model?, type?

[ date, time, stream, class, expver, model, type
[ levtype, number?
[ step, param, levelist?, timespan?none ]]]
8 changes: 8 additions & 0 deletions recipes/fdb/5.19/meta/private/fdb_config/archive.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
type: local
engine: toc
schema: /user-environment/meta/recipe/meta/private/fdb_config/archive.schema
spaces:
- handler: Default
roots:
- path: /scratch/mch/sbolt/icon-archive-data-test