Three fixes after hrrr-point-rs restarts on the first live drain: 1. Type mismatch (hard error): the `profile` column on `hrrr_profiles` is `jsonb[]` (one element per pressure level), but the Rust worker was binding a single jsonb array-of-objects cast as `::jsonb`. Every insert failed with `column "profile" is of type jsonb[] but expression is of type jsonb`. Switched to `Vec<sqlx::types::Json<Value>>`, dropped the explicit `::jsonb` cast, and enabled sqlx's `json` feature so the encoder maps the array into `_jsonb` correctly. 2. Silent zero-inserts: four consecutive 2019-09-22 batches completed with `profiles_inserted: 0` and no diagnostic. Most likely the upstream archive doesn't keep cycles that old, but without a log it looks identical to a snap-mismatch bug. Added a WARN when both surface and pressure grids come back empty so fetch-miss vs. projection-miss is distinguishable. 3. OOMKilled: the pod took four OOM restarts in ten minutes at 1 Gi. A single CONUS decode holds the ~40 MB blob, the ~200 MB wgrib2 working set, AND the full 92k-cell merged map until all requested points drain. 1 Gi has no headroom. Bumped to 2 Gi, matching the rest of the per-container budgets in this namespace.
47 lines
1.2 KiB
TOML
47 lines
1.2 KiB
TOML
[package]
|
|
name = "prop_grid_rs"
|
|
version = "0.1.0"
|
|
edition = "2021"
|
|
publish = false
|
|
|
|
[lib]
|
|
name = "prop_grid_rs"
|
|
path = "src/lib.rs"
|
|
|
|
[[bin]]
|
|
name = "worker"
|
|
path = "src/bin/worker.rs"
|
|
|
|
[[bin]]
|
|
name = "hrrr_point_worker"
|
|
path = "src/bin/hrrr_point_worker.rs"
|
|
|
|
[dependencies]
|
|
tokio = { version = "1", features = ["full"] }
|
|
sqlx = { version = "0.8", features = ["runtime-tokio-rustls", "postgres", "uuid", "chrono", "macros", "json"] }
|
|
reqwest = { version = "0.12", features = ["rustls-tls", "stream"], default-features = false }
|
|
bytes = "1"
|
|
anyhow = "1"
|
|
thiserror = "2"
|
|
tracing = "0.1"
|
|
tracing-subscriber = { version = "0.3", features = ["env-filter", "json"] }
|
|
chrono = { version = "0.4", features = ["serde"] }
|
|
uuid = { version = "1", features = ["v4", "serde"] }
|
|
serde = { version = "1", features = ["derive"] }
|
|
serde_json = "1"
|
|
bincode = "1.3"
|
|
num_cpus = "1"
|
|
byteorder = "1"
|
|
futures = "0.3"
|
|
rayon = "1.10"
|
|
axum = { version = "0.7", default-features = false, features = ["http1", "tokio"] }
|
|
prometheus = { version = "0.13", default-features = false }
|
|
png = "0.17"
|
|
rmp-serde = "1.3"
|
|
rmpv = { version = "1.3", features = ["with-serde"] }
|
|
flate2 = "1"
|
|
|
|
[dev-dependencies]
|
|
tokio = { version = "1", features = ["full", "test-util"] }
|
|
pretty_assertions = "1"
|
|
tempfile = "3"
|