Do you change the connection timeout to 5 seconds?

Updated by Brady Stroud [SSW] 1 year ago. See history

123
<introEmbed body={<> By default, the connection timeout is 15 seconds. When it comes to testing if a connection is valid or not, 15 seconds is a long time for the user to wait. You should change the connection timeout inside your connection strings to 5 seconds. </>} />
"Integrated Security=SSPI;Initial Catalog=SallyKnoxMedical;Data Source=TUNA"

❌ Figure: Figure: Bad Connection String

"Integrated Security=SSPI;Initial Catalog=SallyKnoxMedical;Data Source=TUNA;Connect Timeout=5"

✅ Figure: Figure: Good Connection String with a 5-second connection timeout

Acknowledgements

Adam Cogan
Tiago Araujo
Related rules

Need help?

SSW Consulting has over 30 years of experience developing awesome software solutions.

We open source.Loving SSW Rules? Star us on GitHub. Star