-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Work_Item] (BUG) Ensure all user-defined Tags are encapsulated within the Tags
column
#540
Comments
Summary TF-2 call on Oct 16:#540 [DISCUSSION]: Tags Column Definition and User-Defined Tags |
@cnharris10 Spent some time with this one. I get it now! But I have some feedback. :)
If you feel this level of detail is unnecessary and/or I'm being pedantic, I can appreciate that -- but our audience for these issues is expanding beyond the FOCUS project team, and any/all context will be helpful for someone getting up to speed on this (even a dense Maintainer such as myself!). |
Summary from Members' call on Oct 17:#540 [DISCUSSION]: Tags Column Definition Mandates that User-Defined Tags are Not Altered, Which Can Lead to Various Scenarios
|
Tags
column
Tags
columnTags
column
Tags
columnTags
column
Tags
columnTags
column
I use GCP and Azure and in GCP we have labels and tags, in both labels and tags we have some matching keys. In our FOCUS dataset we dont have any issues in showing the key values from both labels and tags. Might need to do some more investigation into this one. |
@thecloudman Interesting; thanks for sharing. @cnharris10 @AWS-ZachErdman Do we have real-world examples of this happening, and if so, could you share? It may be difficult to get the stakeholders to prioritize this one if it's not perceived to be a problem. |
A couple questions:
If providers follow this approach, then providers will encapsulate some user-defined tags under the standard Example:
The intent of the |
I just tested this with our own data and there is potential collision if their a multiple mechanisms that are resulting in keys that are the same. In the event that the provider has a multiple systems that provide key and values in the tags column then they either need to:
|
I also see the need for this. The spec allowing for namespacing to avoid these collisions seems like the preferable approach here. |
Tags
columnTags
column
An oversight in the specification, and we need to resolve it. |
@cnharris10 this is mainly a problem with respect to cost categories having it's own column and should not be related to the gap that we listed in our user guide for our preview specification. The most compelling problem explanation and argument for me about why we should reconsider this definition is the argument you gave here:
|
Notes from the Maintainers' call on November 4:Context: Practitioners face challenges in tracking resources due to overlaps in tagging structures across providers. This work item seeks to address inconsistencies and potential conflicts in tags by standardizing guidance on user-defined tags. |
Summary from the Maintainers' call on Nov 25Context: |
We don't have this problem in GCP as label keys and tag keys must be unique. In the billing data, tags and labels have separate columns or fields. Although, one could have the same key for labels and tags and assigned to the same resource. It would be accurately reflected in the respective columns. GCP also doesn't have a particular set of schema for tags and labels. GCP aslo uses system labels, these are auto generated metadata that applies to certain resources. System labels are also reported in separate columns. |
Thanks @daviddinhgcp for the added context. For tags/labels, since keys can be the same and Tags is effectively a Map data type, we'll need a way to differentiate - likely allowing prefixes for user-generated k/v pairs. For system labels, these are "provider" tags, and the guidance is to add a provider-provided prefix to these k/v pairs to ensure no clobbering |
Another option - organisations who leverage 2+ tagging schemes should have a tagging standard which defines the key values for each type of tag. For example in Google, they have labels and tags that can be user defined. Labels are the same as tags in azure but tags in gcp are used for automation or assigning policies etc to resources. Therefore, an organisation should have a tagging standard that defines the difference between the two types and clearly outlines the requirements of the two types. Providers must not prefix user defined tags or labels. Providers Must prefix provider defined tags and labels |
Action Items from the Members' call on December 5:
|
@cnharris10 sorry cant tell if you are saying you think we may still have an issue with the Google tags and labels data for some reason? Perhaps we could have collisions across labels and tags (even though labels have to be unique wrt other labels and tags have to be unique wrt other tags) ? or something else? don't the prefixes take care of this? |
@timwright2000 Because tags and labels are user-defined and the current guidance says that user-defined FOCUS tags cannot contain a prefix to namespace collisions, the problem exists within GCP. |
@cnharris10 still getting stuck here.... for GCP, user entered labels are unique, user entered tags are unique... may be easier to discuss live... |
Action Items from the Maintainers' call on December 16:
|
Action Items from the TF-1 meeting on December 17:
|
1. Problem Statement *
In a recent discussion with @AWS-ZachErdman, he mentioned an oversight within the Tags column that at least affects providers with 2+ user-defined tags systems. In this case, AWS (user-defined resource tags, cost categories) and GCP (tags, labels) are affected.
The Tags column currently says: Providers MUST NOT alter user-defined Tag keys or values. In cases where a provider has multiple user-defined tagging features that allow for the same user-defined tags to be created, but partitioned by feature, this will require at least N-1 user-defined features to require some prefix in order to prevent clobbering.
For example, AWS has user-defined both resource tags and user-defined cost categories. If a customer defines a user-defined resource tag as foo:bar and a cost category as foo:baz, then persisting both in the Tags column key/value map will cause clobbering (i.e. either "bar" or "baz" will persist, not both). The same case can occur between GCP tags and labels.
2. Objective *
All user-based or provider-based tags are encapsulated within the
Tags
column with predefined prefixes preventing clobbering for at least N-1 tagging schemes.3. Supporting Documentation *
Original Tags column definition for FOCUS 1.0: #227
Use Case: Analyze cost and usage by multiple tag structures without guessing which columns contain various tags
4. Proposed Solution / Approach
In the proposed approach, using the AWS CUR as an example, the following tags are considered:
User-defined Tags:
foo:bar
(i.e.resourceTags/user:foo
with valuebar
)foo:bar3
(i.e.costCategories/foo
with valuebar3
)Provider-defined Tag:
foo:bar2
(i.e.resourceTags/aws:foo
with valuebar2
)The proposal is to amend the
Tags
column to allow a user-defined prefix to be concatenated with a finalized user-defined tag key for N-1 user-defined tagging schemes. This allows for 1 tagging scheme to remain without a user-definedprefix
, so practitioners can reference a user-defined tagging schema without a prefix.With the tags supplied above, all
Tags
can be co-located as either:Option 1: Predefined prefix declared for N-1 user-defined and all provider tags
Provider declares prefix:
costCategories
for user-defined cost category tags andaws
for provider-defined system tags.Tags: { "foo": "bar", "aws:foo": "bar2", "costCategories:foo": "bar3" }
Option 2: Prefix declared for all user-defined and all provider tags
Provider declares prefix
user
for user-defined resource tags, prefix:costCategories
for user-defined cost category tags, andaws
for provider-defined system tags.Tags: { "user:foo": "bar", "aws:foo": "bar2", "costCategories:foo": "bar3" }
5. Epic or Theme Association
TBD
6. Stakeholders *
TBD
The text was updated successfully, but these errors were encountered: