We have an endpoint (console application) that is running as a windows service and is using MSMQ. This is occurring in both my local (dev) environment and on a UA server when deployed. The endpoint is processing messages more slowly over time. When the endpoint is first started, we place have about 9000+ messages in the queue and it begins processing them quickly. At about the 700-1000 messages processed mark it really begins to slow down. This is causing transaction timeouts and other exceptions. If the services is restarted, it speeds back up again.
CPU usage is 50% when the endpoint is running as well as memory consumption seems to just rise as it starts at about 150 MB and then once everything slows down it’s at about 500 MB.
Raising the transaction scope timeout allows the messages to be processed without timing out, as a work around, but after about 8 hours it was only able to process roughly 2500 messages. Is there anything specific that would cause an endpoint to process messages more slowly over time?
We are using:
NServiceBus version 7.4.7.
.NET Framework 4.7.2 Console application, running as a windows service.