Skip to content

TransactionScope timeout #17

@louiskruger4c

Description

@louiskruger4c

When running queries that take a long time (e.g. creating an index on a large table) we are getting timeouts:

Failure: The transaction associated with the current connection has completed but has not been disposed. The transaction must be disposed before the connection can be used to execute SQL statements.
Erroring script was run in a transaction and was rolled back.

When running the same query using --NOTRANSACTION it does not time out. This leads me to believe that the TransactionScope is timing out. Further reading revealed that TransactionScope has a hidden timeout setting of 1 minute (which corresponds to the timeouts that we are seeing).

I noticed that you increased the SqlCommand timeout to infinite in an earlier change. Would it be prudent to do the same for TransactionScope?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions