Defining Custom Environments
Create custom network topology diagrams using Hava's flexible search and query method.
Last updated
Create custom network topology diagrams using Hava's flexible search and query method.
Last updated
Hava contains the functionality to create custom diagrams using key environment parameters you specify.
This enables you to customise diagrams to just include the key information that is dynamic and ready to view at a glance.
Custom Environment Diagrams can be used to:
Filter and diagram only the specific components of your environment you are interested in viewing
Combine data from separate environments into one diagram
Combine data from separate cloud providers into one diagram
View specific components from multiple sources on the one diagram
The search and filter box at the top of the environments dashboard is the starting point for creating a custom diagram and contains prompts for the available filters.
Select or type the required filter followed by the ID of that resource (no spaces).
The filters are separated by a space. Typing a space after the first resource ID will prompt for the next filter.
You can nominate a single value or stack multiple filters to produce fine tuned custom diagrams.
Returns anything with the matching IP
ip:10.1.1.1 will match the exact IP
ip:10.1.* will match the range
name:
Returns anything with the matching name
name:MyInstance will match the exact name name:My* will match anything starting with ‘My’ name:”My Other Instance” will match a name with spaces or other special characters
project:
Returns everything in the project - works for Google Cloud
region:
Returns anything in the region - works for AWS, Azure, and Google Cloud.
resource_group:
Returns everything in the resource_group - (works for Azure)
source:
Returns anything in this source. The source needs to be selected from the suggestion list.
subnet:
Returns everything in the subnet - works for AWS, Azure and Google Cloud
type:
Returns anything matching the type. The type name needs to be selected from the suggestion list as the format needs to match allowed values.
virtual_network:
Return everything within the Virtual Network for Azure
vpc:
Search for everything in a VPC - (works for Google Cloud and AWS)
vpc:vpc-1234 will return everything in vpc-1234
vpc:vpc-1234 or vpc:vpc-5678 will return both VPCs
Any other value followed by ' : ' (Tags)
Any other token is considered a tag and works across AWS, Azure and Google Cloud
CostCenter:dev will return everything with the tag named CostCenter with the value dev
"aws:deployment:name”:”Test Deployment” will handle tag names and values with spaces or special characters
Location:US* will search for a tag called Location with any values starting with US
The search syntax also provides a set of modifiers and operators allowing you to combine the tokens into complex queries to match resources across all providers, allowing you to define exactly what should be on the diagram.
Allows you to join queries together to limit or expand the results returned.
type:”AWS::EC2::Instance” and vpc:vpc-1234 will search for all resources that are EC2 Instances AND are within the VPC vpc-1234
region:us-west-1 or region:us-west-2 will return resources within us-west-1 OR within us-west-2
By adding a minus ( - ) before your search token you can remove any resources that match a query.
vpc:vpc-1234 and -name:dev-* will return resources that are in the VPC vpc-1234 and don’t have a name starting with ‘dev-’
You can also group a set of tokens together to create more complex queries by surrounding them with brackets.
vpc:vpc-1234 and (CostCenter:dev or CostCenter:test) will return all resources within the VPC vpc-1234 that have the tag CostCenter with a value of either dev or test.
Sometimes you not only want to see the matched resources, but anything connected to them as well. You may want to find your instances but also see their load balancers without having to specify them. Or perhaps you want to see your ECS clusters as well as the instances they are running on.
@type:”AWS::EC2::Instance” will return all instances, as well as connected resources such as load balancers and ECS clusters.
@CostCenter:dev and vpc:vpc-1234 will return all resources with the tag CostCenter and value dev that are in the VPC vpc-1234. It will then also return any resources connected to them as well.
Any resources returned with the deep search operator will be returned after the search is complete, and will not be matched against the query itself. If you search for a specific tag with the deep search operator it may return resources without that tag, for instance.
Using these operators and tokens a range of complex queries can be created.
What you should get in this case is a diagram with two VPCs:
vpc-1234 containing any resources with a CostCenter of either dev or test and aren’t owned by Jim Smith vpc-4567 containing all the databases within it, all the instances within it, and any resources connected to the instances.
Lets say you have two environments set up in separate source AWS accounts and you need a way to easily see the total monthly estimated cost.
We can do this by creating a custom cloud architecture diagram that pulls in environments from the two source accounts.
Click in the Search & Filter box and choose the 'source:' filter from the drop down menu :
Hava will then present you with the available data sources to select from - Select your first source:
Once this is entered, Hava will prompt you for another source. You can keep adding sources or other filters until you have covered all the data you wish to include. In this example, we will add another source :
Select "source:" again, followed by the required second source :
Once the search and filter box has the two required filter parameters, press enter and the new diagram will be created.
Once the new diagram is created, if the results are as you expected, save the diagram by clicking the "save" button next to the filter box and give the new custom cloud environment diagram a meaningful name :
Once saved, the environment view of the new diagram will display a combined visualisation and attribute list.
In this example that includes an attribute list that shows the combined cost estimate that we were interested in viewing.
The data within this new diagram is dynamic and will change as the respective source data changes.
As with all Hava automated interactive diagrams, any major resource changes will trigger a new version of the diagram to be created automatically and the pre state change diagram will be saved in the version history for audit and troubleshooting purposes.
By default, Hava builds diagrams at a VPC or Virtual Network level.
Using the Search and Filter function, you can create custom diagrams. This approach makes it possible to integrate multiple VPC's across accounts and resources, building one diagram view which can be saved.
An example use within AWS architecture would be to display peered VPCs on the same diagram.
To create a multiple VPC diagram, follow these steps :
Identify the VPC ID's you wish to include on the custom diagram.
Create the diagram
Name and save diagram
From the Environments Dashboard, select the environment that contains the first VPC you wish to include on the custom diagram.
Open the diagram by clicking on the relevant tile.
Click on or within the green outer container of the VPC and copy the VPC ID that is displayed on the Attribute Tab underneath the VPC name.
Repeat this process to obtain the second VPC ID
From the top Search and Filter box enter or select vpc: followed by the first VPC ID
Enter a [space] after the first VPC ID and enter vpc: followed by the second VPC ID
Press Enter to create the new custom diagram :
Once the diagram has finished rendering, you can then click on the 'save' button, enter a meaningful name for your new environment, and submit.
Hava will redirect to your new environment.
As you import more resources from your account, Hava will run your custom search again and update the environment content to match.
Your new diagram will now appear on the Environments Dashboard.
The above methodology can be replicated for all of the available search operators.
Some operators are platform specific and more are likely to be added as additional cloud platforms are added to Hava.
region: include everything in the specified region (AWS, Azure, GCP)
vpc: include everything in the corresponding AWS or GCP Virtual Private Cloud
subnet: include everything within the specified subnet id (AWS, GCP, Azure)
virtual_network: include everything in the specified Azure Virtual Network
resource_group: include everything in the specified Azure Resource Group
source: include everything from the source selected from a dropdown (connected cloud account)
ip: include everything that matches or includes the nominated IP (use the full IP and port of the environment ie 10.0.0.0/21 )
name: returns anything with a matching name
project: returns everything in the matching GCP Project
tag:value: Any non reserved text preceding a : will be searched as a tag with the value that follows the : ie CostCenter:Dev finds any resource tagged as "Costcenter" with a value of "Dev"
type: returns resources matching the type selected from a dropdown list