Directories
¶
| Path | Synopsis |
|---|---|
|
console
|
|
|
config
Package config parses the demo console's environment configuration.
|
Package config parses the demo console's environment configuration. |
|
httpui
Package httpui is the demo console's web layer: the router, the handlers, the templates they render, and the one stylesheet those templates load.
|
Package httpui is the demo console's web layer: the router, the handlers, the templates they render, and the one stylesheet those templates load. |
|
reporting
Package reporting is the demo console's read client for the Reporting API.
|
Package reporting is the demo console's read client for the Reporting API. |
|
store
Package store is the demo console's read-only seam over the engine database.
|
Package store is the demo console's read-only seam over the engine database. |
|
core
|
|
|
adjustment
Package adjustment holds the pricing adjustments a project relation carries to the rules they have to match: the surcharges, discounts, project discounts and kickbacks a rated amount passes through.
|
Package adjustment holds the pricing adjustments a project relation carries to the rules they have to match: the surcharges, discounts, project discounts and kickbacks a rated amount passes through. |
|
cardinality
Package cardinality bounds the values a metric label is recorded under, which is what keeps a label whose vocabulary the process does not decide from minting series for as long as it runs.
|
Package cardinality bounds the values a metric label is recorded under, which is what keeps a label whose vocabulary the process does not decide from minting series for as long as it runs. |
|
dbmigrate
Package dbmigrate runs an embedded goose migration chain against a PostgreSQL database.
|
Package dbmigrate runs an embedded goose migration chain against a PostgreSQL database. |
|
envsecret
Package envsecret implements the *_FILE convention every service's configuration follows: a secret may be given inline in its variable or as a path in a companion variable, which is how a Kubernetes Secret volume reaches the process without the value appearing in a pod spec.
|
Package envsecret implements the *_FILE convention every service's configuration follows: a secret may be given inline in its variable or as a path in a companion variable, which is how a Kubernetes Secret volume reaches the process without the value appearing in a pod spec. |
|
event
Package event carries the canonical event schema every platform is normalized into: the wire types, their validation rules, and the categorization that derives an event's effect from its type.
|
Package event carries the canonical event schema every platform is normalized into: the wire types, their validation rules, and the categorization that derives an event's effect from its type. |
|
health
Package health tracks how long a service's checks have been failing, which is what a liveness probe weighs against its threshold before it fails a pod.
|
Package health tracks how long a service's checks have been failing, which is what a liveness probe weighs against its threshold before it fails a pod. |
|
ids
Package ids derives event identifiers.
|
Package ids derives event identifiers. |
|
money
Package money holds the only rounding and division entry points in the system.
|
Package money holds the only rounding and division entry points in the system. |
|
project
Package project names the registry conventions of decision D1 (roadmap/05-phase-5-commercial-pricing.md).
|
Package project names the registry conventions of decision D1 (roadmap/05-phase-5-commercial-pricing.md). |
|
testkit
Package testkit holds the assertions every provider collector is tested against, so that a new provider proves it produces events the core accepts without reimplementing the rules.
|
Package testkit holds the assertions every provider collector is tested against, so that a new provider proves it produces events the core accepts without reimplementing the rules. |
|
timeline
Package timeline folds a resource's event history into the billable intervals it implies.
|
Package timeline folds a resource's event history into the billable intervals it implies. |
|
engine
|
|
|
adjustments
Package adjustments resolves the pricing adjustments a project's relations carry and applies them to the rated amounts of its statement.
|
Package adjustments resolves the pricing adjustments a project's relations carry and applies them to the rated amounts of its statement. |
|
attribution
Package attribution resolves who pays for whose usage: one breadth-first walk over the attributing relations of a billing period, started from every project no relation attributes away.
|
Package attribution resolves who pays for whose usage: one breadth-first walk over the attributing relations of a billing period, started from every project no relation attributes away. |
|
config
Package config parses the metering engine's environment configuration.
|
Package config parses the metering engine's environment configuration. |
|
corrections
Package corrections is the arithmetic and the rendering of a correction run: the amounts one metering and rating pass produced per key, the differences between two such passes, and the credit note every affected project is handed for them.
|
Package corrections is the arithmetic and the rendering of a correction run: the amounts one metering and rating pass produced per key, the differences between two such passes, and the credit note every affected project is handed for them. |
|
counters
Package counters measures the counter metrics of a deployment per usage draft, from the counter sources file the deployment configures.
|
Package counters measures the counter metrics of a deployment per usage draft, from the counter sources file the deployment configures. |
|
export
Package export reads one run back out of the engine database and hands it to a BillingExporter, which is the seam every consumer of billing artifacts sits behind.
|
Package export reads one run back out of the engine database and hands it to a BillingExporter, which is the seam every consumer of billing artifacts sits behind. |
|
invariants
Package invariants holds the usage drafts metering derives for one resource and one billing period to the four checks they must pass before anything is persisted: no gaps or overlaps, coverage, traceability, and an implicit count of one.
|
Package invariants holds the usage drafts metering derives for one resource and one billing period to the four checks they must pass before anything is persisted: no gaps or overlaps, coverage, traceability, and an implicit count of one. |
|
metering
Package metering folds each candidate resource's event history into the usage drafts of one billing period: the intervals the fold implies, clipped to the period, carrying the quantities every later number is derived from.
|
Package metering folds each candidate resource's event history into the usage drafts of one billing period: the intervals the fold implies, clipped to the period, carrying the quantities every later number is derived from. |
|
period
Package period turns the YYYY-MM billing month the engine CLI reads and prints into the interval a run meters over.
|
Package period turns the YYYY-MM billing month the engine CLI reads and prints into the interval a run meters over. |
|
pricing
Package pricing reads a pricing model: the versioned document that says what a unit of every priced metric costs, per platform and resource type.
|
Package pricing reads a pricing model: the versioned document that says what a unit of every priced metric costs, per platform and resource type. |
|
rating
Package rating turns the usage drafts of a billing period into amounts: one per draft and dimension of the pricing entry its resource type carries.
|
Package rating turns the usage drafts of a billing period into amounts: one per draft and dimension of the pricing entry its resource type carries. |
|
runs
Package runs executes one billing period: it takes the period lock, opens a run row, chains metering, counters, rating, attribution and statement rendering over one reporting snapshot, and writes what came out under that run.
|
Package runs executes one billing period: it takes the period lock, opens a run row, chains metering, counters, rating, attribution and statement rendering over one reporting snapshot, and writes what came out under that run. |
|
scheduler
Package scheduler is the hourly tick of the engine: it walks the billing months that have ended, moves each of them from open into grace, and has the month whose grace window has passed metered and, where the deployment asks for it, closed.
|
Package scheduler is the hourly tick of the engine: it walks the billing months that have ended, moves each of them from open into grace, and has the month whose grace window has passed metered and, where the deployment asks for it, closed. |
|
source
Package source is the metering engine's read seam over the Reporting database: a connection pool and, per run, one read-only REPEATABLE READ transaction that every read of that run goes through (D1, D3).
|
Package source is the metering engine's read seam over the Reporting database: a connection pool and, per run, one read-only REPEATABLE READ transaction that every read of that run goes through (D1, D3). |
|
statements
Package statements renders what a billing period is invoiced from: one statement document per top-level project, in the format the concept fixes (docs/explanation/worked-examples.md), holding a line item per resource, a period per usage draft, and the costs of every project attributed to that one beside its own.
|
Package statements renders what a billing period is invoiced from: one statement document per top-level project, in the format the concept fixes (docs/explanation/worked-examples.md), holding a line item per resource, a period per usage draft, and the costs of every project attributed to that one beside its own. |
|
store
Package store is the metering engine's database seam: the pgx connection pool and the migrator that applies the embedded engine chain.
|
Package store is the metering engine's database seam: the pgx connection pool and the migrator that applies the embedded engine chain. |
|
store/storetest
Package storetest hands integration tests a plain PostgreSQL 16 container with the engine migration chain applied.
|
Package storetest hands integration tests a plain PostgreSQL 16 container with the engine migration chain applied. |
|
providers
|
|
|
openstack
Package openstack is the OpenStack event collector: it consumes oslo.messaging notifications from AMQP, maps them to Tally events, buffers them in a SQLite outbox, and posts them to the Reporting API.
|
Package openstack is the OpenStack event collector: it consumes oslo.messaging notifications from AMQP, maps them to Tally events, buffers them in a SQLite outbox, and posts them to the Reporting API. |
|
openstack/osmap
Package osmap holds the vocabulary every OpenStack reader in Tally normalizes with: the divisors the reported quantities are converted by, the nova vm_state table, and which protocol a floating IP is an address of.
|
Package osmap holds the vocabulary every OpenStack reader in Tally normalizes with: the divisors the reported quantities are converted by, the nova vm_state table, and which protocol a floating IP is an address of. |
|
openstack/simulator
Package simulator publishes one simulated month of oslo.messaging notifications.
|
Package simulator publishes one simulated month of oslo.messaging notifications. |
|
Package refdoc renders the parts of the reference pages that state what the code exposes, and checks that the pages still hold what the renderers produce.
|
Package refdoc renders the parts of the reference pages that state what the code exposes, and checks that the pages still hold what the renderers produce. |
|
reporting
|
|
|
audit
Package audit records who changed what in the Reporting API.
|
Package audit records who changed what in the Reporting API. |
|
auth
Package auth authenticates the callers of the Reporting API.
|
Package auth authenticates the callers of the Reporting API. |
|
config
Package config parses the Reporting API's environment configuration.
|
Package config parses the Reporting API's environment configuration. |
|
httpapi
Package httpapi provides primitives to interact with the openapi HTTP API.
|
Package httpapi provides primitives to interact with the openapi HTTP API. |
|
httpapi/problem
Package problem renders the error responses of the Reporting API: RFC 9457 documents served as application/problem+json.
|
Package problem renders the error responses of the Reporting API: RFC 9457 documents served as application/problem+json. |
|
ingest
Package ingest is the batch pipeline every event reaches the reporting database through.
|
Package ingest is the batch pipeline every event reaches the reporting database through. |
|
metrics
Package metrics instruments the Reporting API.
|
Package metrics instruments the Reporting API. |
|
projection
Package projection folds ingested events into current_resources, the one row per (cloud, resource_type, resource_id) that says what a resource is right now.
|
Package projection folds ingested events into current_resources, the one row per (cloud, resource_type, resource_id) that says what a resource is right now. |
|
projects
Package projects holds the domain logic of the project registry: the registration every path that writes a projects row goes through, the point-in-time traversal that answers what a project is related to, and the cycle guard a new cost-attributing relation has to pass.
|
Package projects holds the domain logic of the project registry: the registration every path that writes a projects row goes through, the point-in-time traversal that answers what a project is related to, and the cycle guard a new cost-attributing relation has to pass. |
|
reconciliation
Package reconciliation is the loop that keeps the projection honest.
|
Package reconciliation is the loop that keeps the projection honest. |
|
reconciliation/adapters
Package adapters holds the platform adapters the Reporting API registers for reconciliation.
|
Package adapters holds the platform adapters the Reporting API registers for reconciliation. |
|
registry
Package registry serves the size schemas that resource_types registers per (platform, resource_type).
|
Package registry serves the size schemas that resource_types registers per (platform, resource_type). |
|
stats
Package stats aggregates folded resource histories into the per-window activity the project summary reports: per resource type, how many resources began or ended their life inside the window, and how many minutes they ran within it.
|
Package stats aggregates folded resource histories into the per-window activity the project summary reports: per resource type, how many resources began or ended their life inside the window, and how many minutes they ran within it. |
|
store
Package store is the Reporting API's database seam: the pgx connection pool, the transaction helper every multi-statement write goes through, and the migrator that applies the embedded goose chain.
|
Package store is the Reporting API's database seam: the pgx connection pool, the transaction helper every multi-statement write goes through, and the migrator that applies the embedded goose chain. |
|
store/storetest
Package storetest hands integration tests a TimescaleDB container with the reporting migration chain applied.
|
Package storetest hands integration tests a TimescaleDB container with the reporting migration chain applied. |
Click to show internal directories.
Click to hide internal directories.