Unit cost
FinOps → Unit cost answers “what does one unit of our business cost to run?” for one cluster. A unit is whatever you sell or count: a test, a transaction, a billable hour, an API call, an order. A tenant is whoever the cost is split by: a client, a store, a branch, a customer. Seylo already works out what each namespace costs (chargeback). Unit cost adds the missing half, how many units each tenant produced, which only your own data holds.
The page shows, for each tenant:
- the direct cost of the tenant’s own namespaces;
- its share of the cost nobody owns, apart from the direct cost (see the shared part);
- the total, and the count and the cost per unit, direct or with the shared share;
and for the organisation, one figure; a trend by day or week; a comparison across tenants; and the namespaces that are neither a tenant nor shared. Every number shows where it came from and how old it is.
What it needs
Section titled “What it needs”- Cost per tenant comes from OpenCost in the
seylo-observabilitychart, so cost must be working on the cluster. - Counts come from one of the sources: a query on your database that runs in your cluster, your application, a push, or a CSV. The counts are the only thing that leaves your data, and they are only counts.
Set it up
Section titled “Set it up”-
Open FinOps → Unit cost and pick an industry: healthcare, fintech, consulting, SaaS, e-commerce, or blank. The template fills in the units, the word for a tenant (client, store, branch) and an example. Everything stays editable. Press Save (
admin). -
Check the units. A unit has a name as your data spells it, a plural, an optional description, and how it adds up. Up to 20 per cluster.
Adds up as Meaning Example Sum A week is the sum of its days tests, transactions, API calls Distinct A person counted on Monday and Tuesday is on both days’ counts, and days are never added customers, active users, accounts with activity -
Say who the tenants are. A tenant is a namespace (the default), the value of a pod label such as
customerorclient, or a code in your counts that you map to one or more namespaces or label values on a mapping table. With no row, the tenant’s code is the namespace. A namespace can belong to one tenant only, or its cost would count twice. -
Mark any shared namespaces: platform, monitoring, ingress, anything no single tenant owns. Kubernetes’ own namespaces and Seylo’s are shared already.
-
Connect a count source, then press Check.
Check reads back what Seylo can see: whether the job exists and its last run succeeded, what it refused and why (a code, never a value), the newest count per tenant and unit from every source, and which cost each tenant’s code maps to. Each problem comes with the sentence that fixes it.
How the cost per unit is worked out
Section titled “How the cost per unit is worked out”Each day (UTC) a tenant’s direct cost is the cost of its namespaces, priced the same way as the cost table. It covers compute: CPU, memory and GPU. Storage and network stay on the Cost tab.
Then:
- A day with no count is “no count reported”. It is never 0 and never filled in from other days. A reported 0 is a real 0, and the cost per unit on it is undefined, and says so.
- For a sum unit, a week or a window is the cost of the days that have a count, divided by the units of those days. Days with no count are named and left out of both sides. The tenant’s cost over the window still includes every day.
- A distinct unit is never added: not across days (the window shows the mean of the daily figures, and says so) and not across tenants.
- Hourly counts add into their day for a sum unit, and the page says “the sum of N hourly counts; an hour with no count is not counted”.
- Two sources for the same tenant, unit and day are refused for that day. They are never added or picked between, and the page names both.
- Days before the cost store’s history are left out, not shown as $0.
- A price that is missing says why. A tenant whose cost has an unpriced part shows Not priced or at least, with the reason.
The organisation’s figure
Section titled “The organisation’s figure”The organisation’s cost per unit divides the tenants’ cost (with the shared part, for “with shared”) by the organisation’s count:
- For a sum unit, the count is the one you send under the tenant code
_all, if you send it. Otherwise it is the tenants’ counts added, on days every tenant that ran reported one. - For a distinct unit it is
_allor nothing. A shopper who buys from two stores would be counted twice if the tenants’ counts were added, so Seylo does not add them. Send a distinct count under_allto get the organisation’s figure.
The shared part
Section titled “The shared part”Some cost belongs to no tenant: the namespaces you marked shared, idle capacity and cost the cost engine cannot attribute. The page shows it apart from every tenant’s direct cost, with the rule that split it and each tenant’s share. Choose the rule:
| Rule | How the shared cost is split |
|---|---|
| Usage (default) | In proportion to each tenant’s direct cost that day. This is the weighting chargeback uses for share idle, so the two pages agree |
| Even | Equal parts to every tenant that ran that day |
| Weight | In proportion to weights you set per tenant |
The shares add up to the shared cost exactly, to the micro-dollar. If a split cannot be known, Seylo refuses it and gives the reason instead of a number: part of the shared cost is unpriced; under Usage, a tenant’s own cost is unpriced; under Weight, a tenant that ran has no weight, or every weight is 0. The direct figures stand, and with shared says why it is missing.
You can leave idle and unattributed cost out of the shared part. The page then says the totals no longer add up to what the nodes cost.
Other namespaces are neither a tenant nor shared. They are shown apart with their cost and receive no share, because spreading them silently would be a decision nobody took. One click marks one of them shared.
Who sees what
Section titled “Who sees what”| Role | Can |
|---|---|
viewer |
See the page for the tenants whose namespaces their access allows |
admin |
Save the setup, upload a CSV, create and revoke push tokens |
Someone whose access is limited to some namespaces sees the direct cost of the tenants in those namespaces. They do not see the shared part, idle, other tenants’ counts or the organisation’s figure, because each is a fact about namespaces they cannot see. The page says so.
Privacy
Section titled “Privacy”Only counts leave your database, and only counts are stored. A result, a push and a CSV must be exactly tenant, unit, day (or hour) and count. Anything else refuses the whole batch. Use a tenant’s code, never a person’s name: Seylo cannot tell a code from an identifier, and it stores the codes you send. See send counts to Seylo.