question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

server.connection-timeout default value

See original GitHub issue
	/**
	 * Time in milliseconds that connectors will wait for another HTTP request before
	 * closing the connection. When not set, the connector's container-specific default
	 * will be used. Use a value of -1 to indicate no (i.e. infinite) timeout.
	 */
	private Integer connectionTimeout;

I don’t know if this is a bug or a feature. However, I definitely feel that this is not reasonable, in tomcat, the default connectionTimeout value is 2000. In spring boot, however, he does not have a default value, causing the system to have a large number of TIME_WAIT. I think a default value should also be given when it is automatically transferred. Not Null or 0.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:12 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
wilkinsonacommented, Feb 9, 2018

Tomcat’s default is 60 seconds. Spring Boot will leave Tomcat to use that default unless you have configured it. I’ve just verified this behaviour using one of our samples.

If you want someone to spend some more time looking at this, then you’ll need to provide a small sample that shows Spring Boot configuring Tomcat with a timeout other than its default.

0reactions
happier2commented, May 9, 2020

@wilkinsona no,no,no

you can use ab -k to request , connection TIME_WAIT too.

By default, nginx will use protocal http/1.0 to connect with your spring boot application, which will cause lots of short connection between nginx and tomcat. Lots of short connection(frequently open tcp and close tcp) will produce lots of TIME_WAIT.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Spring Boot Application - what is default timeout for any rest ...
server.connection-timeout= # Time in milliseconds that connectors will wait for another HTTP request before closing the connection.
Read more >
Using Tomcat connectionTimeout Attribute to Defend Against ...
By default, the value of this attribute is set to 60000 (i.e. 60 seconds). If you reduce this value, you can limit the...
Read more >
Timeout settings for HTTP and HTTPS communication - IBM
The default value is 120 seconds. [server] client-connect-timeout = 120; intra-connection-timeout. This stanza entry affects request and response data sent ...
Read more >
[#EMAIL-100] The default connection timeout should be set to ...
Socket connection timeout value in milliseconds. Default is 1 minute. @since 1.2 */ public static final String MAIL_SMTP_CONNECTIONTIMEOUT = "mail.smtp.
Read more >
Don't trust default timeouts | Roberto Vitillo's Blog
Javascript's XMLHttpRequest is THE web API to retrieve data from a server asynchronously. Its default timeout is zero, which means there is no ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found