https://github.com/jetty-project/selector-hack
Experimental project demonstrating how to hack the Selector within Eclipse Jetty
https://github.com/jetty-project/selector-hack
experimental selector selector-hack windows workaround
Last synced: 10 months ago
JSON representation
Experimental project demonstrating how to hack the Selector within Eclipse Jetty
- Host: GitHub
- URL: https://github.com/jetty-project/selector-hack
- Owner: jetty-project
- License: other
- Created: 2020-09-29T14:17:59.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2024-11-04T16:24:13.000Z (about 1 year ago)
- Last Synced: 2025-01-23T22:14:18.873Z (12 months ago)
- Topics: experimental, selector, selector-hack, windows, workaround
- Language: Java
- Homepage:
- Size: 160 KB
- Stars: 1
- Watchers: 7
- Forks: 1
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Experimental Selector Hack for Eclipse Jetty
On some machines, the NIO Selector shows signs of a buggy implementation
that spuriously wakes up the selector to report 0 selected keys.
The symptoms of this kind of OS / Network driver bug is 100% CPU usage.
Example: https://github.com/eclipse/jetty.project/issues/2205
This repository contains an experimental ServerConnector that will
rebuild there are consecutive select of 0 that exceeds `WorkaroundManagedSelector.MAX_NO_SELECT`.
To use this alternate ServerConnector would require substituting usages of
`org.eclipse.jetty.server.ServerConnector` with the special one provide in here
`org.eclipse.jetty.server.WorkaroundServerConnector`.
**NOTICE:** Do not use this workaround if you don't have the above mentioned bugs on your
system, as the performance of this workaround will negatively impact systems without
the selector bug.