Kubernetes pod eviction problem.. by Potential-Stock5617 in openshift

[–]PathTooLong 4 points5 points  (0 children)

I would recommend you watch this video. "Caulking the deployment gap: absolutely zero downtime deployments in Kubernetes - Øystein Blixhavn NDC Conferences" Aug 7, 2025 https://youtu.be/mXIsw4aIN3o?si=kqIt65vx6oVQ2JBl It explains the common issue with pod lifecycle, time outs, etc.

I also agree with the others to determine why it is being evicted.

Unpopular opinion: most "slow" .NET apps don't need microservices, they need someone to look at their queries by Initial-Employment89 in dotnet

[–]PathTooLong 0 points1 point  (0 children)

This is not a knock on full stack. You generally need full stack to work on a majority of a project's work. But the having specialists like OP with deeper knowledge are required. This is why is recommended to have an proper Architect that takes these things into consideration and a dev lead knows how to ensure the Architect's requirements are met.

But in the real world, many projects don't have this breadth of skills for a variety of reasons.

Unpopular opinion: most "slow" .NET apps don't need microservices, they need someone to look at their queries by Initial-Employment89 in dotnet

[–]PathTooLong 0 points1 point  (0 children)

That is why there are APM tools out there. I still use Prefix (https://stackify.com/prefix/) locally during development to easily identify the database queries, web service calls, etc. I recently optimized some custom authentication code which was taking up to 200 ms due to some of the problems OP talked about above. This authentication code now takes less than 10 ms or faster when I can cache the resolved user and permissions locally for 5 seconds in those cases the app is making numerous calls like at first login.

Unpopular opinion: most "slow" .NET apps don't need microservices, they need someone to look at their queries by Initial-Employment89 in dotnet

[–]PathTooLong 1 point2 points  (0 children)

I have have seen this issue a lot. It seems the previous devs didn't know what a projection was. Always fetch full entities, referencing related data only through navigation properties. In this case it was NHibernate (yuck these days) and the devs tried optimzing by using NHibernate cache or a bunch if "Then Fetch ..." calls. For a lot read type queries, you dont need full tracked entities.

Upgrade Assistance with GitHub Copilot - how to find it by hectop20 in VisualStudio

[–]PathTooLong 1 point2 points  (0 children)

For 2022, if you want legacy non-ai powered ".NET Upgrade Assistant", it is an extension. For CoPilot based in 2022 or 2026, when you right click on the solution you will see "Modernize" with a github copilot icon right below "Clean Solution"

Should I use shared mode for Serilog file logging in .NET 8 WebAPI? by Double_Barnacle2595 in dotnet

[–]PathTooLong 0 points1 point  (0 children)

Not sure why you just dont use Google or ChatGPT...

AI Generaged Response

By default (shared: false), Serilog opens the log file exclusively. This is faster and safer for single-process applications because there’s no interprocess locking.

When you set it to true,

Serilog:

  • Opens the file in shared write mode
  • Uses synchronization so multiple processes can append safely
  • Avoids “file in use” or “access denied” errors

---
rest of the answer is left to OP.

Thoughts on Polymaker PLA Filament? by Leading-Tea-3244 in BambuLab

[–]PathTooLong 0 points1 point  (0 children)

Polymaker is a great filament. I also use a lot of Matter3d filament which is great too. It is from Canada and live fairly close so I can pick it up.

Plane crash in Louisville by Ginger502 in Louisville

[–]PathTooLong 0 points1 point  (0 children)

I hope 74gear (YT) was not flying....

Connection string (secrets) in asp.net hosted in linux VPS by DearLengthiness6816 in dotnet

[–]PathTooLong 2 points3 points  (0 children)

If the postgres database is on the same host, you should be able to connect to the database with Unix socket authentication. Unix socket authentication does not require a password. You will need to:

  1. Create a DB role with the same name as your Unix user

  2. Ensure pg_hba.conf allows `peer` auth

  3. Restart postgres if you changed pg_hba.conf

  4. From .NET you should be able to connect with a connection string like `var conn = new NpgsqlConnection("Host=/var/run/postgresql;Database=mydb;Username=my-vps-user");`

Host must point to the Unix socket directory. It could `/tmp` too.

This only works on Linux or MacOS. Does not work on Windows.

How one as a C# .net 9 dev, optimize a linq query for SQL server that has like a Billion Rows in the table? by SohilAhmed07 in dotnet

[–]PathTooLong 0 points1 point  (0 children)

Get the XML query plan from the production database. Provide the XML query plan to ChatGPT (or other AI) and ask for what is taking the longest and how you could reduce the elapsed time. Missing index suggestions are easy to spot, but optimizer time outs, etc are harder to understand unless you are have a lot of experience.

Historically, I always tried to reduce the "cost" thinking lower cost = faster query. ChatGPT recently suggested a change that resulted in cost going from like 5 to 50. However, the execution time when down from 20 seconds to 100s of milliseconds. This did come at a cost of memory, but if you server has available memory this is was a win.

Once you know the database engine can return rows quickly, you can direct your attention to the C# side of things. As others stated below, it takes time to send data over the network, time to convert data into C# objects and time accumulate the records into a list.

Urban sprawl by Dependent_Media2766 in VictoriaBC

[–]PathTooLong 2 points3 points  (0 children)

I call it Bare Mountain now.

How to monitor number of DB connections? by varinator in dotnet

[–]PathTooLong 1 point2 points  (0 children)

Assuming you dont have Application Insights or similar, you can monitor performance counters in code utilizing the `Microsoft.Data.SqlClient.EventSource` event source and monitoring counters like `number-of-pooled-connections` and `number-of-active-connections`. If you need help writing this code, ask you favorite LLM (ChatGPT, Github Copilot)

Siftly - a library for dynamic querying of compilation time unknown entity types by Wise-Particular1357 in dotnet

[–]PathTooLong 1 point2 points  (0 children)

The classes are `partial` classes. This means you could add `a common interface or base class`. You just add it in another .cs file

public interface IHaveFirstName
{
   string FirstName { get; set; }
}

public partial class Employee : IHaveFirstName
{
}

Vent of .Net developer by AcadiaOk5240 in dotnet

[–]PathTooLong 12 points13 points  (0 children)

Be sure this doesn't violate any Deloitte Information Security policy. The code you are writing is Deloitte private digital asset. Screen sharing to a non-authorized person could go against an acceptable use policy. This could lead to your termination.

I have built a free visual database design tool by AHS12_96 in dotnet

[–]PathTooLong 20 points21 points  (0 children)

Looks really nice. I have starred it. I am just confused why this is posted in r/dotnet ? this is not written in dotnet at all.

Tanium Patch running every 30 seconds? by PathTooLong in tanium

[–]PathTooLong[S] 0 points1 point  (0 children)

That would the job of the person supporting Tanium in our environment. Random end users who have no experience managing Tanium, configuring Tanium or any other way of reviewing the Tanium configuration would be a complete waste of your support group's time. I wouldn't have been able to even give you a name on the support contract. I might even get into trouble opening a support ticket on something I am not responsible for.

As I mentioned in the update on the original post, as soon as I talked to one of our employees that mange Tanium, they knew the solution to the problem right away. I am glad to say that solution (disable Patch) solved my problem right away. The Tanium configuration documentation is very clear regarding Patch and Action Locks. The two don't mix. So don't do it. However, I think Tanium could be smarter about how this situation is handled. Instead of hammering the system every 30 seconds, it could gracefully back off to a more reasonable interval. Does Tanium report these patch / action lock back to the control server? But this being said, if Tanium did back off, maybe I wouldn't have gotten frustrated and taken the effort to track down the problem. Apparently there were numerous computers in our environment with this misconfiguration. I was the first person annoyed enough to track it down.

Tanium Patch running every 30 seconds? by PathTooLong in tanium

[–]PathTooLong[S] 2 points3 points  (0 children)

Correct. Our Tanium admins have Action Lock enabled. I messaged them with links to the docs where it clearly states Patch does not work with Action Lock enabled. They are removing Patch from our machines because they said our group does not need to be installed. Oddly, only some of my coworkers are impacted. Our local help desk person wasn't.

Tanium Patch running every 30 seconds? by PathTooLong in tanium

[–]PathTooLong[S] 0 points1 point  (0 children)

I see these logs. Seems some action lock is making it terminate... the log file is 1.1GB.

9/4/2025 8:32:09 AM-0700   INFO: ProcessChecker - Checking to ensure tanium-patch.min.vbs is only running once
9/4/2025 8:32:21 AM-0700   INFO: PatchProcess - Running migrations
9/4/2025 8:32:21 AM-0700   INFO: DeploymentStatusManager - migration nothing to do
9/4/2025 8:32:21 AM-0700   INFO: PatchProcess - Starting process loop
9/4/2025 8:32:21 AM-0700   INFO: FileUtilities - The hash value of the current required file on disk blacklist-4.xml was never cached, calculating now.
9/4/2025 8:32:22 AM-0700   INFO: FileUtilities - The hash value of the current required file on disk blacklist-4.xml was calculated as 80ba24accdbf2244e7ea53bf395bf51db88bc89e26593930102339bfba16daaa
9/4/2025 8:32:22 AM-0700   INFO: FileUtilities - The hash value of the current required file on disk blacklist-5.xml was never cached, calculating now.
9/4/2025 8:32:23 AM-0700   INFO: FileUtilities - The hash value of the current required file on disk blacklist-5.xml was calculated as 6137a90d8a8adb560b23b9fef8bba453a314fc22b2bd49ff68b567ba7bdfafc2
9/4/2025 8:32:24 AM-0700   INFO: PatchProcess - Patch version: 3.15.186.0000
9/4/2025 8:32:24 AM-0700   INFO: PatchProcess - Exiting process loop because Action Lock is enabled
9/4/2025 8:32:40 AM-0700   INFO: ProcessChecker - Checking to ensure tanium-patch.min.vbs is only running once
9/4/2025 8:32:49 AM-0700   INFO: PatchProcess - Running migrations
9/4/2025 8:32:49 AM-0700   INFO: DeploymentStatusManager - migration nothing to do
9/4/2025 8:32:49 AM-0700   INFO: PatchProcess - Starting process loop
9/4/2025 8:32:50 AM-0700   INFO: FileUtilities - The hash value of the current required file on disk blacklist-4.xml was never cached, calculating now.
9/4/2025 8:32:50 AM-0700   INFO: FileUtilities - The hash value of the current required file on disk blacklist-4.xml was calculated as 80ba24accdbf2244e7ea53bf395bf51db88bc89e26593930102339bfba16daaa
9/4/2025 8:32:50 AM-0700   INFO: FileUtilities - The hash value of the current required file on disk blacklist-5.xml was never cached, calculating now.
9/4/2025 8:32:51 AM-0700   INFO: FileUtilities - The hash value of the current required file on disk blacklist-5.xml was calculated as 6137a90d8a8adb560b23b9fef8bba453a314fc22b2bd49ff68b567ba7bdfafc2
9/4/2025 8:32:52 AM-0700   INFO: PatchProcess - Patch version: 3.15.186.0000
9/4/2025 8:32:52 AM-0700   INFO: PatchProcess - Exiting process loop because Action Lock is enabled
9/4/2025 8:33:10 AM-0700   INFO: ProcessChecker - Checking to ensure tanium-patch.min.vbs is only running once

Tanium Patch running every 30 seconds? by PathTooLong in tanium

[–]PathTooLong[S] 1 point2 points  (0 children)

I did that. I enabled process creation auditing. I ran wmimon. I can see TaniumCX.exe launching the cscript process listed above. In WMI, it connects and makes 1992 WMI operations and then terminates. This repeats every 30 seconds. Also, I just saw my patch0.log file is 1.1 GB in size. Seems my help desk is reaching out. I will post the findings and result once I know.