Best Practices While Building Perspectives
search cancel

Best Practices While Building Perspectives

book

Article ID: 284354

calendar_today

Updated On:

Products

CloudHealth

Issue/Introduction

CloudHealth Perspectives provide a framework for categorizing all the assets within your infrastructure.

  • It is recommended that you cleanup empty groups as it allows for better performance as perspectives are very resource intensive.

One quick way to check for empty groups is by performing a simple

Ctrl + f command searching for ‘assets 0’.

  • This will highlight each empty group as well as give the count.
  • To remove these groups, simply click the broom icon to begin cleanup.

NOTE: The automated cleanup process will not remove dynamic groups with more than one filter assigned.

  • Verify the assets in the ANA (Assets Not Allocated) group
  • Always Tag your assets!
  • To get the most out of the Perspective's:
    • Use tagged assets with a refined tagging policy that is not loose/unstructured.
    • Tags are case sensitive.
    • We always recommend implementing consistency guidelines.

NOTE: If you change the value of an Asset's tag and that Asset already belongs in a Perspective Group, then when Perspectives are rebuilt, that Asset will be re-grouped according to its new tag.

 

Resolution

Building your Perspectives

  • Start with the Categorize approach first, and then use Search.
  • Avoid Simple Search, if possible, because it returns a large number of false positives.
  • Review the assets that make up each list to make sure they have been correctly allocated.
  • If the number of asset categories is more than 200, then CloudHealth Support can help you increase the group limit or can assist you in categorizing the assets.
  • CloudHealth Perspectives provide a framework for categorizing all the assets within your infrastructure.

 
Special Consideration
If a new tag falls under a different Perspective Group, then the asset will move between the old and new group.
 
If you have configured 'Dynamic' Perspective Groups, then a new group will be created if the tag value doesn't already exist in another group.
 
If that new tag does not belong to any Perspective Group and you're not using Dynamic Perspective Groups, then it will fall under the catch-all 'Assets Not Allocated' group.
 
Once the Perspective has been updated, overnight processing will apply the new perspective to all reports.  This means that the reports will reflect the Asset residing in the new Perspective Group (or Asset Not Allocated), including all historical months within the live report.
 
Note: Changes to Asset Tags and Perspectives will not impact Archived reports.
 
Tags and Perspectives – CloudHealth (cloudhealthtech.com)
 
Build a perspective using a tag for categorization
 

What's the best way to build a perspective using a tag for categorization?
The two main asset types you will want to use when creating a perspective are:

  • "Asset"
  • "Amazon Taggable Asset"

It is important that you follow these steps in order to ensure you capture all appropriate infrastructure into your perspective.
 
The first step will be to run the perspective group search with "Asset":

CloudHealth has created an asset gather tree for the majority of AWS infrastructure under the "Asset" asset type.  This means that not only will taggable assets like EC2 instances be recognized and pulled in to the perspective groups, but also associated infrastructure that can't be tagged directly.  Once these groups are recognized, pull them in to the perspective.

Since the "Asset" gather tree asset type is maintained by CloudHealth, there is a chance that it may not include all taggable assets available (generally newly released assets may not show up) so it's a best practice to run the process again using "Amazon Taggable Asset".

 
Within the same perspective, run the group search a second time using "Amazon Taggable Asset" as this is a direct feed from AWS:

The most likely result is that no additional groups appear but this extra step serves to ensure you have all taggable assets captured within the perspective you are building.  If additional groups do appear, simply add or merge them in to the appropriate group within the perspective you are building.

A Perspective is one lens into your cloud infrastructure. It contains one or more Perspective Groups.
 
Build Perspective Groups and allocate assets to these Groups.
 
Step 1: Create Perspective
 

The perspective editor appears with a list of assets that are not allocated to any Perspective Group.

As you begin to create Groups, the number and percentage of Assets Not Allocated decreases and the Assets Allocated percentage increases.

Assets not allocated

Optional: Create Placeholder Groups as containers that you can later use to gather cloud assets.

Create Perspective Group

 
Step 2: Decide How to Gather Cloud Assets

There are three ways in which you can use CloudHealth to query your cloud infrastructure for assets that match a pattern, based on your needs I would suggest "Search by Attribute". As you know the specific asset attribute you want to find but also the specific value that attribute should have.

 
Examples:
 
tag cht_owner = 'Person'
Active = 'true'
Account Name = 'CloudHealth' AND Tags 'My TAG'
tag subFunction = 'workers' OR tag subFunction = 'queues'
Semantic example: Get all instances and related assets that have a Chef run-list that contains the role web_server.
Groups Created: One per query.
 
The Best practice: Start with the Categorize approach first, and then use Search. Avoid Simple Search, if possible, because it returns a large number of false positives.
 
Approach 2: Search

While this approach requires several steps to gather assets of interest, it enables you to select specific criteria for discovering asset groups using fields when asset tags are unavailable.

In the perspective editor, select an Asset Type from the dropdown.

In the Search Filters, select a field you want to filter against during search.

 
Set Filters
 
Dynamic Groups

Dynamic Groups are created from a single or multiple categorization rule. Assets are automatically allocated to or removed from a Perspective group without your intervention. They provide you a way to create a Group for every unique value of the categorization field and keep it up-to-date without any ongoing intervention.

 

For example, consider that you are using a tag key environment that currently has one of three values: production, staging, and qa. When you create a dynamic group based on the categorization rule that creates groups based on the unique values of the environment tag, CloudHealth creates three Perspective Groups: production, staging, and qa. A month from today, if you start tagging assets with environment = development, the same categorization rule automatically creates a new development group. Based on the Asset Type you chose to categorize with, all the assets tagged with that value get allocated to the new group.

 
Things You Need to Know About Dynamic Groups

Since tag values are case sensitive, Perspective groups are as well. For instance, if you tag your infrastructure with Prod, prod, and Production, it will create three separate groups, although they all refer to the same environment.

You can merge and unmerge dynamic groups within a dynamic group Block. For example, if you create the groups Production and prod using categorization, but they all represent the same environment, you can merge them in the CloudHealth platform. Later, if you want, you can unmerge them into separate groups too. However, merging and unmerging groups is possible only with dynamic groups. For more information, see Manage Perspective Groups.

You can merge two or more dynamic group blocks as well to automatically merge groups with the same name from two different categorization rules. For example, there are two dynamic group blocks. The first group block has an AWS instance category rule on environment creating groups prod, staging, dev, and another group block has an AWS volume category rule on environment creating groups prod, staging, test. If these two dynamic group blocks are merged, the resulting groups would be: prod, staging, dev, test. The groups prod and staging would represent merged dynamic groups.

You cannot delete an individual group in a dynamic group block. The trash can icon or Delete All option will delete all the groups present in the dynamic group block.

You can delete an empty group in a dynamic group block only if the Perspective group has one rule. If the perspective group has an additional filter on it, you need to remove the filter first before deleting the empty group.

 
Static Groups

Static Groups are also created from a single categorization rule or through Search, and can be expanded if discovered assets match the existing rule. The assets matching the rule will be automatically added to the appropriate Perspective groups. However, in case of changes in the tags on assets, you need to manually add updated groups to the Perspective that are built using static groups.

For Static Groups, a Perspective will not create a new group for the given categorization rule. For example, You created a Perspective group using the categorize by Owner tag. Using the Add all option, you created a different group for each owner. When a user owner: Vikram adds a new asset and tags it with his name, the Perspective will be automatically updated and includes his new asset in the group labeled Vikram. However, if a new employee named Alyssa joins and she tags her resources Owner: Alyssa, the Perspective will not create a new group for her because there are no groups categorized on Alyssa.

 

Placeholder Groups

The Placeholder Groups are blank groups you manually create to reallocate indirect or direct costs. Click Group on the right side to Add Placeholder Group. For more information, see Cost Reallocation.

 
 
Create Dynamic Groups (Categorize only)

This option allows you to create multiple Dynamic Groups at the same time to your Perspective. Groups created by this method can expand and contract as you add or remove attribute values for your assets.

 
Dynamic Rule
 
Click Add All as Dynamic Rule, provide a Name to the group, select a color to represent groups and click Add Dynamic Group.