From 83d4816438bbf47b48f5884559bc8306288e492a Mon Sep 17 00:00:00 2001 From: a4plane Date: Tue, 24 Dec 2024 19:18:37 +0900 Subject: [PATCH] =?UTF-8?q?net8=EB=A1=9C=20=EB=B9=8C=EB=93=9C=ED=95=A8=209?= =?UTF-8?q?=EB=A1=9C=20=ED=96=88=EC=97=88=EB=8A=94=EB=8D=B0=20vs=EB=B2=84?= =?UTF-8?q?=EC=A0=84=20=EC=97=85=EB=8D=B0=EC=9D=B4=ED=8A=B8=20=EC=95=88?= =?UTF-8?q?=ED=95=B4=EC=84=9C=20=EB=B9=8C=EB=93=9C=EA=B0=80=20=EC=95=88?= =?UTF-8?q?=EB=90=A8=20=EC=8A=A4=EC=BD=94=EC=96=B4=20=EC=96=BB=EB=8A=94=20?= =?UTF-8?q?=EB=B6=80=EB=B6=84=20=EB=A1=A4=EB=B0=B1=ED=95=A8=20=EC=95=84?= =?UTF-8?q?=EB=A7=88=20=EA=B3=A0=EC=B3=90=EC=A1=8C=EC=9D=84=EB=93=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- rtjiory/Program.cs | 11 +++++------ rtjiory/rtjiory.csproj | 4 ++-- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/rtjiory/Program.cs b/rtjiory/Program.cs index 15a3c4d..21673c0 100644 --- a/rtjiory/Program.cs +++ b/rtjiory/Program.cs @@ -69,7 +69,7 @@ app.MapPost("submit", (string name, int score) => List weekArrow = []; //weekly Jobs (dbReset, WeekArrowGen...) -System.Timers.Timer resetTimer = new(10000); // 10000ms = 10 seconds => 1week = ?ms mol ra si bal +System.Timers.Timer resetTimer = new(43200000); // 10000ms = 10 seconds => 1week = ?ms mol ra si bal resetTimer.Elapsed += (sender, e) => { //TimeOnly curTime = new(DateTime.Now.Hour, DateTime.Now.Minute); @@ -81,7 +81,7 @@ resetTimer.Elapsed += (sender, e) => //weekArrow.Clear(); // Log reset actio var logger = app.Services.GetRequiredService>(); - //logger.LogInformation("doWeekJobs"); + logger.LogInformation("do every 12hour Jobs"); // Clear the scoreDB scoreDBini.Clear(); @@ -101,13 +101,12 @@ resetTimer.Elapsed += (sender, e) => // int rngNum = (int)random.NextInt64(0, 4); // weekArrow.Add(rngNum/*(int)random.NextInt64(0, 4)*/); // //logger.LogInformation(rngNum.ToString()); -//}//ÀÚ±â ÀÚ½ÅÀÌ ÀаíÀÖ´Ù°í ¸ø ÀÐÀ¸¸é ³­ ¹¹ ¾î¶»°Ô ¹Þ¾Æµé¿©¾ßÇÔ? => resetTimer°¡ ¸ÞÀÎ ½º·¹µå°¡ ¾Æ´Ñ ´Ù¸¥ ½º·¹µå¿¡¼­ µ¿ÀÛÇÑ´Ù´Â Ä«´õ¶ó°¡ ÀÖÀ½ +//}//ÀÚ±â ÀÚ½ÅÀÌ ÀаíÀÖ´Ù°í ¸ø ÀÐÀ¸¸é ³­ ¹¹ ¾î¶»°Ô ¹Þ¾Æµé¿©¾ßÇÔ? => resetTimer°¡ ¸ÞÀÎ ½º·¹µå°¡ ¾Æ´Ñ ´Ù¸¥ ½º·¹µå¿¡¼­ µ¿ÀÛÇÑ´Ù´Â Ä«´õ¶ó°¡ ÀÖÀ½ => jobiniŬ·¡½º¿¡¼­ ¸Þ¼­µå Çϳª »©¸Ô¾ú´Ù°í »ý±ä ¹®Á¦Àεí? ¾Æ¸¶ ÇØ°áµÊ resetTimer.Start(); //±â·ÏµÈ Á¡¼ö ¾ò±â app.MapGet("/", () => /*scoreDB);*/scoreDB = scoreDBini.ReadDictionary());//scoreDBini.ReadDictionary); -app.MapGet("WeekArrow", () => weekArrow -); +app.MapGet("WeekArrow", ()=> weekArrow); //app.UseHttpsRedirection(); app.UseStaticFiles(); @@ -120,5 +119,5 @@ app.UseRouting(); app.MapRazorPages(); -//À̹Ìminio¿¡¼­ 8000~8001»ç¿ëÁß +//À̹Ìminio¿¡¼­ 8000~8001»ç¿ëÁß => ±Ùµ¥ ¿Ö 8004¾¸? ±×³É app.Run("http://localhost:8004"); diff --git a/rtjiory/rtjiory.csproj b/rtjiory/rtjiory.csproj index 1245750..e167363 100644 --- a/rtjiory/rtjiory.csproj +++ b/rtjiory/rtjiory.csproj @@ -1,7 +1,7 @@ - + - net9.0 + net8.0 enable enable AnyCPU;ARM64