-
Notifications
You must be signed in to change notification settings - Fork 116
Comparing changes
Open a pull request
base repository: kohlschutter/junixsocket
base: junixsocket-2.8.1
head repository: kohlschutter/junixsocket
compare: junixsocket-2.8.3
- 12 commits
- 29 files changed
- 2 contributors
Commits on Oct 3, 2023
-
Configuration menu - View commit details
-
Copy full SHA for 43cbb88 - Browse repository at this point
Copy the full SHA 43cbb88View commit details
Commits on Oct 27, 2023
-
Fix concurrency issue from modifying the selectedKeysSet
This bug may have been a regression introduced in optimizing the key removal: a7c3106 To reproduce refer to poc: https://github.com/kevink-sq/jetty-concurrency-issue-poc To verify fix, refer to poc branch (same as these changes): https://github.com/kevink-sq/jetty-concurrency-issue-poc/tree/kevink/attempted-junixsocket-fix-2 Jetty's [ManagedSelector](https://github.com/jetty/jetty.project/blob/7a7d69a69f4f51772e20813332291189a24e91b1/jetty-io/src/main/java/org/eclipse/jetty/io/ManagedSelector.java#L655) iterates through the selectedKeysSet and when separate processes cancel the AFSelectorKey, the iterator throws a `ConcurrentModificationException`. Fix is to introduce `cancelledKeysSet` to defer removal of cancelled keys until the select process. Use of the cancelled sets are referenced from java.nio.channels.spi's `AbstractSelector` and `AbstractSelectionKey`. Ideally we'd have `AFSelectionKey` extend from `AbstractSelectionKey` to leverage the base class's internal cancelled set but`AbstractSelectionKey` defines its own `isValid` and `cancel` and cannot override the base's final methods. Also added an atomic check to `AFSelectionKey#cancel` to prevent "Too many open files" socket exception.
Configuration menu - View commit details
-
Copy full SHA for b8386a1 - Browse repository at this point
Copy the full SHA b8386a1View commit details -
Configuration menu - View commit details
-
Copy full SHA for 0943b15 - Browse repository at this point
Copy the full SHA 0943b15View commit details -
Configuration menu - View commit details
-
Copy full SHA for 819eeb6 - Browse repository at this point
Copy the full SHA 819eeb6View commit details -
Configuration menu - View commit details
-
Copy full SHA for f0bafd4 - Browse repository at this point
Copy the full SHA f0bafd4View commit details
Commits on Nov 12, 2023
-
Revert "Fix concurrency issue from modifying the selectedKeysSet"
This reverts commit b8386a1.
Configuration menu - View commit details
-
Copy full SHA for 4b2bfc8 - Browse repository at this point
Copy the full SHA 4b2bfc8View commit details -
Fix concurrency issue with AFSelector
Clients may iterate upon AFSelector.selectedKeys() while the selected keys are modified in another thread. Change the underlying datastructure to be thread-safe (use ConcurrentHashMap), and add all "ready" selectors even if they're marked invalid (they will be removed later). We reimplement the fix as the original patch caused a FileDescriptor leak and TIPC test failures. #142 #145
Configuration menu - View commit details
-
Copy full SHA for 889ca99 - Browse repository at this point
Copy the full SHA 889ca99View commit details -
AFSelector: Use single ConcurrentHashMap for registered/selected keys
Since we already have a ConcurrentHashMap, let's make use of the value, which now indicates the "selected" state. Introduce MapValueSet, which is a view over elements of the "keysRegistered" map, and precisely only those elements that have a certain value. For each call to select, we increment the expected value, and then set only the actually selected entries to that value, so we don't have to clear the entire map. #145
Configuration menu - View commit details
-
Copy full SHA for 470e426 - Browse repository at this point
Copy the full SHA 470e426View commit details -
AFSelector: Bring back Java 7 compatibility
Fix errors only occurring with -Drelease #145
Configuration menu - View commit details
-
Copy full SHA for efacb5a - Browse repository at this point
Copy the full SHA efacb5aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0f700aa - Browse repository at this point
Copy the full SHA 0f700aaView commit details -
Configuration menu - View commit details
-
Copy full SHA for cfec208 - Browse repository at this point
Copy the full SHA cfec208View commit details -
Update site dependency for 2.8.x only
In 2.9.0, we will a newer kohlschutter-parent.
Configuration menu - View commit details
-
Copy full SHA for 45d0700 - Browse repository at this point
Copy the full SHA 45d0700View commit details
This comparison is taking too long to generate.
Unfortunately it looks like we can’t render this comparison for you right now. It might be too big, or there might be something weird with your repository.
You can try running this command locally to see the comparison on your machine:
git diff junixsocket-2.8.1...junixsocket-2.8.3