Skip to content
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

Allow for pluggable algorithm to choose next EventLoop #1230

Closed
normanmaurer opened this issue Apr 2, 2013 · 9 comments
Closed

Allow for pluggable algorithm to choose next EventLoop #1230

normanmaurer opened this issue Apr 2, 2013 · 9 comments
Assignees
Milestone

Comments

@normanmaurer
Copy link
Member

At the moment we just choose the next EventLoop based on some modulo operation. This may be not optimal for some reasons as there may be one EventLoop which is more busy as the other. Optimal we would allow to plugin the agorithm.

buchgr added a commit to buchgr/netty that referenced this issue May 25, 2014
Motivation:

Currently when a new event loop is needed to register a channel our EventLoopGroup implementations just
use a round-robin like algorithm to choose the next event loop. Unfortunately this is not always good
enough as different event loops may become more busy than others over time. This is especially true when
an application handles different kinds of connections (long-living and short-living). This change allows
developers to plug in their own algorithms to choose the next event loop and to collect metrics about the
busyness of the event loops. See netty#1230

Modifications:

- TODO

Result:

- Developers can plug in their own algorithms into MultithreadEventLoopGroup constructors.
- Developers can gather metrics/feedback from the event loops and use the data in their custom algorithms.
buchgr added a commit to buchgr/netty that referenced this issue Aug 5, 2014
Motivation:

Currently when a new event loop is needed to register a channel our EventLoopGroup implementations just
use a round-robin like algorithm to choose the next event loop. Unfortunately this is not always good
enough as different event loops may become more busy than others over time. This is especially true when
an application handles different kinds of connections (long-living and short-living). This change allows
developers to plug in their own algorithms to choose the next event loop and to collect metrics about the
busyness of the event loops. See netty#1230

Modifications:

- TODO

Result:

- Developers can plug in their own algorithms into MultithreadEventLoopGroup constructors.
- Developers can gather metrics/feedback from the event loops and use the data in their custom algorithms.
buchgr added a commit to buchgr/netty that referenced this issue Aug 6, 2014
Motivation:

Currently when a new event loop is needed to register a channel our EventLoopGroup implementations just
use a round-robin like algorithm to choose the next event loop. Unfortunately this is not always good
enough as different event loops may become more busy than others over time. This is especially true when
an application handles different kinds of connections (long-living and short-living). This change allows
developers to plug in their own algorithms to choose the next event loop and to collect metrics about the
busyness of the event loops. See netty#1230

Modifications:

- TODO

Result:

- Developers can plug in their own algorithms into MultithreadEventLoopGroup constructors.
- Developers can gather metrics/feedback from the event loops and use the data in their custom algorithms.

bla
buchgr added a commit to buchgr/netty that referenced this issue Aug 10, 2014
Motivation:

Currently when a new event loop is needed to register a channel our EventLoopGroup implementations just
use a round-robin like algorithm to choose the next event loop. Unfortunately this is not always good
enough as different event loops may become more busy than others over time. This is especially true when
an application handles different kinds of connections (long-living and short-living). This change allows
developers to plug in their own algorithms to choose the next event loop and to collect metrics about the
busyness of the event loops. See netty#1230

Modifications:

- TODO

Result:

- Developers can plug in their own algorithms into MultithreadEventLoopGroup constructors.
- Developers can gather metrics/feedback from the event loops and use the data in their custom algorithms.
@Scottmitch
Copy link
Member

@jakobbuchgraber @normanmaurer - It seems like this was resolved by #2470? I am cleaning up 5.0.0.Alpha2 assignment and let me know if this is in error.

@buchgr
Copy link
Contributor

buchgr commented Sep 23, 2014

@Scottmitch no it wasn't. it will be resolved by #2788 ... waiting for review :)

@Scottmitch Scottmitch reopened this Sep 23, 2014
@Scottmitch
Copy link
Member

@jakobbuchgraber - Thanks for the clarification. I am also going to move this issue to 5.0.0.Alpha3 with PR #2788 (see my last comment in that PR).

@Scottmitch Scottmitch modified the milestones: 5.0.0.Alpha3, 5.0.0.Alpha2 Sep 23, 2014
@Scottmitch
Copy link
Member

@jakobbuchgraber - The re-assignment is in support of #2933.

@danhyun
Copy link

danhyun commented Jun 12, 2015

Hello, I'm trying to find the status of this work but last I see it seems that @buchgr is no longer legally allowed to continue work on this effort. Is this something that's still planned for release?

@trustin trustin modified the milestone: 5.0.0.Alpha3 Mar 7, 2016
@normanmaurer normanmaurer added this to the 4.1.0.Final milestone Apr 12, 2016
normanmaurer added a commit that referenced this issue Apr 14, 2016
]

Motivation:

Sometimes it may be benefitially for an user to specify a custom algorithm when choose the next EventExecutor/EventLoop.

Modifications:

Allow to specify a custom EventExecutorChooseFactory that allows to customize algorithm.

Result:

More flexible api.
normanmaurer added a commit that referenced this issue May 20, 2016
]

Motivation:

Sometimes it may be benefitially for an user to specify a custom algorithm when choose the next EventExecutor/EventLoop.

Modifications:

Allow to specify a custom EventExecutorChooseFactory that allows to customize algorithm.

Result:

More flexible api.
@normanmaurer normanmaurer modified the milestones: 4.1.0.Final, 4.1.1.Final May 26, 2016
normanmaurer added a commit that referenced this issue Jun 4, 2016
]

Motivation:

Sometimes it may be benefitially for an user to specify a custom algorithm when choose the next EventExecutor/EventLoop.

Modifications:

Allow to specify a custom EventExecutorChooseFactory that allows to customize algorithm.

Result:

More flexible api.
normanmaurer added a commit that referenced this issue Jun 6, 2016
]

Motivation:

Sometimes it may be benefitially for an user to specify a custom algorithm when choose the next EventExecutor/EventLoop.

Modifications:

Allow to specify a custom EventExecutorChooseFactory that allows to customize algorithm.

Result:

More flexible api.
@normanmaurer
Copy link
Member Author

Fixed by #5279

liuzhengyang pushed a commit to liuzhengyang/netty that referenced this issue Sep 10, 2017
…tty#1230]

Motivation:

Sometimes it may be benefitially for an user to specify a custom algorithm when choose the next EventExecutor/EventLoop.

Modifications:

Allow to specify a custom EventExecutorChooseFactory that allows to customize algorithm.

Result:

More flexible api.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants