Tagging for Cost Allocation

0

I have a client running thier datacenter on AWS. They use many of the AWS services including Amazon Glue and Amazon Medical Comprehend-NLP services. They would like to use tagging feature to allocate the cost for the respective business units and external business partners. For both the services, I mentioned above they would like to setup an automation for dynamically assign tags while creating jobs. For example, leveraging an input parameter "business-unit_1 for marketing, and "business-unit_2 for finance for internal business units as well as for external business partners.

Thanks,

  • How are they creating glue jobs etc. through cloudformation, codepipeline or what?

4 Answers
0

Thanks Jose! I am not able to access to the link that you shared. It is asking for workdocs login credentials which I don't have.

answered 10 months ago
0

Jose, same result.

answered 10 months ago
0

From your question, it is not clear what the input parameter is for. If the input parameter is for the cloudformation script that creates the Job, you can use cloudformation mappings to map the parameter values to the exact tag value needed on the resource. If the job resource already exists in a shared account and you are looking for a way to tag the Job execution to allocate the cost of running the job based on an input argument, unfortunately that is not possible using tags. You can only tag Glue resources, not specific Job Runs. To do chargebacks in this case, a cloudwatch event rule can be triggered when the Job completes (SUCCEEDED, FAILED, TIMEOUT). The rule can invoke a lambda that queries the job run for the job name using Glue.Client.get_job_runs, and get information about the Job run like the Job arguments, DPUSeconds etc. The lambda can then publish a custom metric to cloudwatch with business unit as a dimension. At the end of the month you can use aws cloudwatch get-metric-statistics to get a report of who ran the Jobs.

AWS
sahniks
answered 10 months ago
0

Thank you! Sorry for not asking you question clearly, but that is what exactly I was looking for for AWS Glue. I would also assume that the same process can be used for the Amazon Medical Comprehend by using input parameter for the Cloudformation template. Correct!

answered 10 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions