Skip to content

Commit

Permalink
FOCUS #181: Usage Unit Dimension
Browse files Browse the repository at this point in the history
Spec change for Usage Unit: A unit of measurement for consumption or usage of resources or services
  • Loading branch information
amitw-g authored and udam-f2 committed Nov 13, 2023
1 parent 9d45b33 commit a40f329
Show file tree
Hide file tree
Showing 3 changed files with 67 additions and 0 deletions.
1 change: 1 addition & 0 deletions specification/dimensions/dimensions.mdpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,6 @@ dimensions to categorize, filter, and reveal details in your data when grouped w
!INCLUDE "subaccountid.md",1
!INCLUDE "subaccountname.md",1
!INCLUDE "tags.md",1
!INCLUDE "usageunit.md",1

[FODOFC]: https://www.finops.org/framework/capabilities/
46 changes: 46 additions & 0 deletions specification/dimensions/usageunit.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# Usage Unit

Usage Unit refers to a unit of measurement for consumption or usage of resources or services. Usage Unit may differ from published Pricing Unit when providers use different units,  unit increments, or dimensions for calculating cost.  This unit is commonly used when auditing or reconciling consumption or billing data.

The UsageUnit column MUST be present and MUST NOT be null or empty. This column is of type String and MUST be composed of the list of recommended units if it is possible to be expressed in the set of possible units. Composite units made from combinations of recommended units is also allowed. E.g. GB/Month.Instead of "per" or "-" to denote a Composite Unit, slash ("/") SHOULD be used as a common convention.  Count based units like requests, instances, tokens SHOULD be expressed as count.  

## Column ID

UsageUnit

## Display name

Usage Unit

## Description

A unit of measurement for consumption or usage of resources or services

## Content constraints

| Constraint | Value |
|:----------------|:----------------|
| Column required | True |
| Data type | String |
| Allows nulls | True |
| Value format | \<not specified> |

## Recommended Unit Set

| TIME_UNIT | DATA_UNIT | COUNT_UNIT | PREFIXES |
|------------------|-----------|--------------|-----------------|
| s: second | bit: bit | count: count | Ki: kibi (2^10) |
| min: minute | B: byte | | Mi: mebi (2^20) |
| h: hour | | | Gi: gibi (2^30) |
| d: day | | | Ti: tebi (2^40) |
| wk: week | | | Pi: pebi (2^50) |
| mo: month | | | K: Kilo (10^3) |
| yr: year | | | M: Mega (10^6) |
| ms: milli-second | | | G: Giga (10^9) |
| us: micro-second | | | T: Tera (10^12) |
| ns: nano-second | | | P: Peta (10^15) |


## Introduced (version)

1.0
20 changes: 20 additions & 0 deletions supporting_content/dimensions/usageunit.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Usage Unit

## Example provider mappings 

Current column mappings found in available data sets:

| Provider | Data set | Provider column |
|-----------|-------------------------|------------------------|
| AWS | CUR | Pricing_unit |
| GCP | BigQuery Billing Export | usage_unit |
| Microsoft | Cost details | UnitOfMeasure Quantity |

## Example scenarios for current provider data

Current values observed in billing data for various scenarios:
| Provider | Provider Column | Example Value |
|----------|-----------------|-----------------------------------------------------------------|
| AWS | pricing_unit | Gigabyte | Month | Requests| GB-MONTH | Hrs| Seconds |
| GCP | Usage_unit | Gigabyte | hour| mebibyte| second| month |
| Azure | UnitOfMeasure | 1 GB | 1 GB/Month | 100 Hours | 1/Day | 10K | 1 GiB Second |

0 comments on commit a40f329

Please sign in to comment.