Skip to content
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

Add Functionality to Ignore Nearly expired RIs with Specified Tags #4

Merged
merged 6 commits into from
Jun 13, 2023

Conversation

mashiike
Copy link
Contributor

@mashiike mashiike commented Jun 7, 2023

This pull request introduces a new feature to exclude expired Reserved Instances (RIs) when specific tags are associated with them, preventing them from being displayed as expired. The motivation behind this feature is to enhance the efficiency of frequent riex executions by excluding RIs that are nearing their expiration date but are already acknowledged.

To achieve this, the functionality leverages the capability of tagging EC2, Elasticache, and RDS instances with Reserved Instances. When a specified tag is present, the associated RIs are considered acknowledged and will be ignored, ensuring they are not included in the display results.

Please review and provide feedback on this pull request. Thank you!

Behavier

For example, RDS RI

スクリーンショット 2023-06-13 10 40 20

in default:

$ go run cmd/riex/main.go 90 --format markdown
| service | name | description | instance_type | count | start_time | end_time | state |
| --- | --- | --- | --- | --- | --- | --- | --- |
| RDS | example-hoge-hoge | aurora-mysql | db.t4g.medium | 1 | 2022-07-01T00:00:00Z | 2023-07-01T00:00:00Z | active |

if add --ignore-tags key1=value1;key2=value2

$ go run cmd/riex/main.go 90 --ignore-tags riex=recognized --format markdown

Currently, it is assumed that the recognized tags are attached manually.

@mashiike mashiike changed the title Add Functionality to Exclude Expired RIs with Specified Tags Add Functionality to Exclude Nearly expired RIs with Specified Tags Jun 7, 2023
@mashiike mashiike changed the title Add Functionality to Exclude Nearly expired RIs with Specified Tags Add Functionality to Ignore Nearly expired RIs with Specified Tags Jun 13, 2023
@fujiwara fujiwara merged commit 4ade303 into fujiwara:main Jun 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants