Skip to content

src/cosmos: a cosmos sql source with a query file, day window and shaping (0.8.0) - #17

Merged
royashbrook merged 3 commits into
mainfrom
16-cosmos-source
Oct 14, 2026
Merged

royashbrook merged 3 commits into
mainfrom
16-cosmos-source

Conversation

@royashbrook

@royashbrook royashbrook commented Oct 1, 2026 •

Copy link
Copy Markdown
Owner

adds a cosmos source, src/cosmos. it posts cosmos sql over rest with the account key, so no sdk on the runner. 0.8.0.

a feed keeps its query in get-data.sql, same as a sql feed. set InputFile, or put it inline in Query. if the query uses @day, @from or @to, those go in too. @day is AS_OF or yesterday. @from and @to are a Days window ending with it.

Fresh stops the run if the container's last load is too old.

cosmos drops a value it doesn't have from that record. so every record gets every column, empty if missing, and a file never shifts.

the rest gateway won't do aggregates or order by across partitions. cosmos sql has no date formats or lookups by a computed key either. so Formats, Map, Sort and Drop do those after the read.

tested: acceptance passes, 144 checks. new cosmos checks fail on the first draft. i ran sixteen feeds against their current readers for ten days, read only. every day matched byte for byte.

refs #16

🤖 Generated with Claude Code

https://claude.ai/code/session_01Jub9tSz3bzXLyvDJ6iUd2F

…0) (refs #16)

the query comes from Query or an InputFile in the job directory. @day, @from and @to are the day a run
reports (AS_OF, or yesterday) and a Days window ending with it, sent only when the query uses them.
Fresh stops the run when the container's last load is too old. a record gets every column any record
has, so a missing value is an empty cell, not a shifted file. Formats, Map, Sort and Drop do what the
rest gateway cannot: date formats, code to name maps, and order by across partitions.
@royashbrook royashbrook changed the title src/cosmos: a cosmos sql query over rest as a source (0.8.0) src/cosmos: a cosmos sql source with a query file, day window and shaping (0.8.0) Oct 14, 2026
@royashbrook
royashbrook marked this pull request as ready for review October 14, 2026 17:53
@royashbrook

Copy link
Copy Markdown
Owner Author

the corrected head is bf85db9e4330fbb074b914e61f23c5a734ce2395. src/cosmos now explicitly requires PowerShell 7.5 for ConvertFrom-Json -DateKind; existing adapters keep the 7.4 baseline. the packaged brief documents that distinction, and README lists ten adapters.

my offline rerun passes 144 acceptance checks, helper pins, capability inventory and negative/CRLF checks. all six current CI checks are green. no live provider call or consumer change.

merge and release remain held for the fresh exact-head review of this small delta.

@royashbrook
royashbrook merged commit b9255ee into main Oct 14, 2026
6 checks passed
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.

1 participant