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

Review Actions interface #2

Open
flowersinthesand opened this issue Mar 20, 2015 · 0 comments
Open

Review Actions interface #2

flowersinthesand opened this issue Mar 20, 2015 · 0 comments

Comments

@flowersinthesand
Copy link
Member

Actions is a powerful interface to define a specific event using Action and usually used internally by event firer. Typically, it backs up method like oneventname(Action<Event> action) internally and change in Actions doesn't affect event firer's API. Though, since it's very useful, it would be nice for user to use it for their own purpose. However, the following points should be considered to encourage doing that.

  • Interface name
    Actions is vague name and is named from jQuery's Callbacks object that was inspiring to write Actions interface. ActionStack, ActionPipeline or EventDefiner, and so on look better.
  • A way to configure option
    I'm not sure which way is better among setter, POJO option, option builder, and so on but clearly it's not needed to change such option in runtime as it defines a specific event.
  • Flow control
    Considering various events, flow of executing action should be able to be controlled by event firer or listener. Sometimes actions should be executed in a row asynchronously or synchronously and also sometimes firing should be stopped by some condition. (For example, a process to find proper cettia transport in client may be one of usages using this.) Many ways are available: 1. A special class extending ThreadLocal to acquire flow controller 2. A special action to control flow 3. A special method on Actions to control flow. We need to find more flow control cases and determine how to achieve that. Substituting event object in firing event may be required as well.
  • Benchmark Netty and Grizzly
    Both frameworks have similar component e.g. Pipeline and Filter. See what functionalities should be provided.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant