CrazyIter_Bin há 4 anos atrás
pai
commit
eea90be99f

+ 6 - 5
TEAMModelFunction/MonitorServicesBus.cs

@@ -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)
             {

+ 1 - 0
TEAMModelFunction/TEAMModelFunction.csproj

@@ -2,6 +2,7 @@
   <PropertyGroup>
     <TargetFramework>netcoreapp3.1</TargetFramework>
     <AzureFunctionsVersion>v3</AzureFunctionsVersion>
+    <_FunctionsSkipCleanOutput>true</_FunctionsSkipCleanOutput>
   </PropertyGroup>
   <ItemGroup>
     <Compile Remove="AServiceBus.cs" />