Jetty has moved!
Jetty is a project at the Eclipse Foundation.
Homepage:http://www.eclipse.org/jetty
Downloads: http://download.eclipse.org/jetty/
Documentation:http://www.eclipse.org/jetty/documentation/current/
About:http://www.eclipse.org/jetty/about.php
Jetty Powered:http://www.eclipse.org/jetty/powered/
Contact the core Jetty developers at www.webtide.com
private support for your internal/customer projects ... custom extensions and distributions ... versioned snapshots for indefinite support ... scalability guidance for your apps and Ajax/Comet projects ... development services from 1 day to full product delivery
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

No warning starting Jetty on port already in use (on Windows)

This is a peculiarity of the implementation of the ServerSocketChannel on the Windows platform and effects the SelectChannelConnector. See also the Sun bug 4546610.

The work around is to use the setReuseAddress(false) on the SelectChannelConnector. By default, this value is set to [true], and enables the socket option [SO_REUSEADDRESS]. This means that a socket may be opened, even if there is previous close (ie the port is in [TIME_WAIT] state) still pending on that socket. Setting it to [false] does not permit the socket to be re-opened in that state, but it also allows an Exception to be thrown if the socket is in use, eg by another Jetty instance.

  • No labels
Contact the core Jetty developers at www.webtide.com
private support for your internal/customer projects ... custom extensions and distributions ... versioned snapshots for indefinite support ... scalability guidance for your apps and Ajax/Comet projects ... development services from 1 day to full product delivery