Deadlocks when starting NServicebus service damage connection

We are launching NServiceBus for a web application to handle situations when the user performs "batch actions". Like fire, a team that affects 1,000 objects.

This works well, but under moderate load we get some deadlocks, this is not a problem, just repeat the message. correctly?:)

The problem occurs when the following message arrives and tries to open a connection. The connection is then “damaged”.

We get the following error: System.Data.SqlClient.SqlException (0x80131904): a new request does not start because it must have a valid transaction descriptor

I searched on the Internet and I think our problem is the NH "bug" message :

The workaround should be to disconnect the connection pool. But I do not like it, because the performance will be deteriorating.

We are launching NServiceBus 2.6, NHibernate 3.3.

Does anyone have any experience? Can an NServiceBus update help?

+5
source share
2 answers

I saw this in the past, if your design guarantees, try to split the transaction into two parts, if you completely transfer the message transaction to your database operations, any failures will have a cascading effect, and this will affect (ideally this shouldnt) any subsequent messages also.

+1
source

, 1000 , , , , , , . , , 1000 , . , , -. , - : , 1 , 2 , ..

0

All Articles