Maskoe
Maskoe
CC#
Created by Maskoe on 3/2/2024 in #help
minimal api DI magic
now i hav to add "dude just add this CancellationToken thing, that you dont use, to the function signature, BUT only if you actually use the HttpContext"
9 replies
CC#
Created by Maskoe on 3/2/2024 in #help
minimal api DI magic
yea I saw that its just pretty funny, i was making a minimal example sample to show someone how easy and simple aspnetcore is compared to the go example he showed me. And immediately I ran into some weird cryptic gotcha that I needed like 2 hours to solve and im a 5 year experience all in on c# and aspnetcore andy 😹
9 replies
CC#
Created by Maskoe on 3/2/2024 in #help
minimal api DI magic
okay at least its only rider, not vs :Ok:
9 replies
CC#
Created by Maskoe on 3/2/2024 in #help
minimal api DI magic
No description
9 replies
CC#
Created by Maskoe on 3/2/2024 in #help
minimal api DI magic
pretty sure I just found a bug :thinkang: I can inject absolutely anything and do the pretty syntax anything but HttpContext IHttpContextAccessor works, [FromBody] works, random services work
9 replies
CC#
Created by Maskoe on 3/2/2024 in #help
minimal api DI magic
Adjusted my question..
9 replies
CC#
Created by Maskoe on 1/31/2024 in #help
Razor MVC UI reuse
hmm doesnt look right
4 replies
CC#
Created by Maskoe on 10/25/2023 in #help
❔ Coldstart issues?
ehhh i dont know about the "not resetting" thing. After like 10 hours when I woke up the first request took 2.3sec again. The 2nd 300ms.
21 replies
CC#
Created by Maskoe on 10/25/2023 in #help
❔ Coldstart issues?
yea i played around a little im pretty sure its the assembly loading thing. Even an empty endpoint goes from first run 60ms to 2nd run 6ms. So I guess its loading certain things for the first time when doing the whole http request response de/serialization handling thing. And I guess loading all the ef core assemblies just takes a while. I remember running into this couple years back too. When I was performance tuning queries locally, I always had to run it several times cause you couldnt trust the first run. Didnt know about jit back then.
21 replies
CC#
Created by Maskoe on 10/25/2023 in #help
❔ Coldstart issues?
its probably just the first call after a deploy / restart
21 replies
CC#
Created by Maskoe on 10/25/2023 in #help
❔ Coldstart issues?
yea i'd assume so I will keep an eye on my deployments then
21 replies
CC#
Created by Maskoe on 10/25/2023 in #help
❔ Coldstart issues?
it shouldnt, right?
21 replies
CC#
Created by Maskoe on 10/25/2023 in #help
❔ Coldstart issues?
okay, i understand jit somewhat when does it "reset"? In an always on app service / api?
21 replies
CC#
Created by Maskoe on 10/18/2023 in #help
❔ EF Core optional where extension method
.WhereIfNotNull(myId, x => x.Id == myId) vs .Where(x => myId == null || x.Id == myId)
8 replies
CC#
Created by Maskoe on 10/18/2023 in #help
❔ EF Core optional where extension method
yea but these barely gain anything in being more concise, if its now 2 arguments in the method, instead of 2 conditions in the where clause
8 replies
CC#
Created by Maskoe on 2/18/2023 in #help
❔ Trying to generify List Func Task
oh wait, youre right jesus christ man, sometimes I get lost 😫
4 replies
CC#
Created by noam.rees on 1/29/2023 in #help
❔ WPF game in C# having trouble attaching the "fireball" (image) to the player(ImagePlayer)
I dont know the answer, but just play around with the Canvas.SetLeft and SetTop methods. Put in 0, see where that makes the ball show up. Put in 100, see where that makes the ball show up... etc Debug, or print out the value thats in player.ImagePlayer.RenderTransformOrigin.X and you'll figure it out
6 replies
CC#
Created by Maskoe on 1/14/2023 in #help
❔ Smart way to code an insurance pricing calculation with explanation?
in a way these are just logs or traces right? no one writes their tracing like that. people just bite the bullet and throw in logger.LogTrace("did xy") everywhere
16 replies
CC#
Created by Maskoe on 1/14/2023 in #help
❔ Smart way to code an insurance pricing calculation with explanation?
and you need to pass variables etc
16 replies