|
@@ -18,8 +18,10 @@ namespace TEAMModelFunction
|
|
|
private readonly AzureCosmosFactory _azureCosmos;
|
|
|
private readonly DingDing _dingDing;
|
|
|
private readonly AzureStorageFactory _azureStorage;
|
|
|
- private readonly AzureRedisFactory _azureRedis;
|
|
|
- public MonitorServicesBus(AzureCosmosFactory azureCosmos, DingDing dingDing, AzureStorageFactory azureStorage, AzureRedisFactory azureRedis)
|
|
|
+ private readonly AzureRedisFactory _azureRedis;
|
|
|
+ public MonitorServicesBus(AzureCosmosFactory azureCosmos, DingDing dingDing, AzureStorageFactory azureStorage
|
|
|
+ , AzureRedisFactory azureRedis
|
|
|
+ )
|
|
|
{
|
|
|
_azureCosmos = azureCosmos;
|
|
|
_dingDing = dingDing;
|
|
@@ -154,10 +156,9 @@ namespace TEAMModelFunction
|
|
|
jsonMsg.RootElement.TryGetProperty("code", out JsonElement name);
|
|
|
var client = _azureStorage.GetBlobContainerClient($"{name}");
|
|
|
var size = await client.GetBlobsSize();
|
|
|
- await _dingDing.SendBotMsg($"ServiceBus,Blob() 容器:{name}更新大小:{size}",
|
|
|
- GroupNames.醍摩豆服務運維群組);
|
|
|
await _azureRedis.GetRedisClient(8).HashSetAsync($"Blob:Record",new RedisValue($"{name}"),new RedisValue($"{long.Parse($"{size}")}"));
|
|
|
-
|
|
|
+ await _dingDing.SendBotMsg($"ServiceBus,Blob() 容器:{name}更新大小:{size}",
|
|
|
+ GroupNames.醍摩豆服務運維群組);
|
|
|
}
|
|
|
catch (Exception ex)
|
|
|
{
|