-
-
Save justinyoo/1a6867fd33b7fb2fc6e8efdb26e05383 to your computer and use it in GitHub Desktop.
Know Your Cloud Resource Costs on Azure
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public async Task TakeActionAsync(ResourceGroupOwner owner, bool runEntirePeriod, decimal threshold) | |
{ | |
var owners = owner.Owners.Split(new[] { ";" }, StringSplitOptions.RemoveEmptyEntries); | |
// Use SendGrid or Twillio or whatever to send alerts/warnings. | |
var sb = new StringBuilder(); | |
sb.AppendLine($"An alert has been sent to {string.Join(" & ", owners)}"); | |
Console.WriteLine(sb.ToString()); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment