-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use addEventListener(EventListener listener) instead of bespoke listener methods #3966
Conversation
Signed-off-by: Greg Wilkins <gregw@webtide.com>
Use addEventListener rather than bespoke listener methods. Support getEventListenerBeans at Container level for fast lookup improve javadoc Signed-off-by: Greg Wilkins <gregw@webtide.com>
fixed test more javadoc Signed-off-by: Greg Wilkins <gregw@webtide.com>
fixed tests Signed-off-by: Greg Wilkins <gregw@webtide.com>
I don't like this. |
Same as @joakime. |
Resolve differences between eventListeners added as beans and beans added as EventListeners. The behaviour should now be the same regardless of how they listener is added and all listeners are now beans. Signed-off-by: Greg Wilkins <gregw@webtide.com>
Add only SelectorManager listeners to manager from connector Signed-off-by: Greg Wilkins <gregw@webtide.com>
Signed-off-by: Greg Wilkins <gregw@webtide.com>
Fixed javadoc Signed-off-by: Greg Wilkins <gregw@webtide.com>
removed old TODO Signed-off-by: Greg Wilkins <gregw@webtide.com>
@joakime @sbordet come on! you've got to give better reviews than "I don't like it"! What code verbose? I have more lines, but mostly because I've actually added some javadoc? How is this more difficult to maintain? Previously we have had a managery of different listeners, some Why is it "needless"? This clean up avoids several needless iteration over beans and ArrayList creations on every new connection and new HttpChannel (which can be every request in http2). So it is a non-trivial saving of effort. |
connector cannot be null Signed-off-by: Greg Wilkins <gregw@webtide.com>
Doh! I have found an issue with this approach - MBeanListener, which is on every bean if JMX is enabled makes this a non optimal approach. Consider this a draft again until I find a better way. |
javadoc Signed-off-by: Greg Wilkins <gregw@webtide.com>
fixed merge Signed-off-by: Greg Wilkins <gregw@webtide.com>
Signed-off-by: Greg Wilkins <gregw@webtide.com>
jetty-util/src/main/java/org/eclipse/jetty/util/component/Container.java
Outdated
Show resolved
Hide resolved
jetty-server/src/main/java/org/eclipse/jetty/server/session/SessionHandler.java
Outdated
Show resolved
Hide resolved
removed the ability to set/clear context listeners Instead just remove non-durable ones. Signed-off-by: Greg Wilkins <gregw@webtide.com>
Signed-off-by: Greg Wilkins <gregw@webtide.com>
Signed-off-by: Greg Wilkins <gregw@webtide.com>
Signed-off-by: Greg Wilkins <gregw@webtide.com>
Signed-off-by: Greg Wilkins <gregw@webtide.com>
…2578-EventListener Signed-off-by: Greg Wilkins <gregw@webtide.com>
Signed-off-by: Greg Wilkins <gregw@webtide.com>
Signed-off-by: Greg Wilkins <gregw@webtide.com>
…2578-EventListener
@janbartel @joakime re-review please |
…2578-EventListener Signed-off-by: Greg Wilkins <gregw@webtide.com>
jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java
Outdated
Show resolved
Hide resolved
jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java
Show resolved
Hide resolved
* Fixed tests that scan for "Started" on console Signed-off-by: Greg Wilkins <gregw@webtide.com>
jetty-ant/src/main/java/org/eclipse/jetty/ant/AntWebAppContext.java
Outdated
Show resolved
Hide resolved
jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java
Show resolved
Hide resolved
jetty-server/src/main/java/org/eclipse/jetty/server/handler/ContextHandler.java
Show resolved
Hide resolved
jetty-servlet/src/main/java/org/eclipse/jetty/servlet/ServletContextHandler.java
Show resolved
Hide resolved
jetty-util/src/main/java/org/eclipse/jetty/util/component/Container.java
Outdated
Show resolved
Hide resolved
Signed-off-by: Greg Wilkins <gregw@webtide.com>
Signed-off-by: Greg Wilkins <gregw@webtide.com>
…2578-EventListener
For #2578 (includes #3965 for #3964):