netty/netty — Issue #212: Allow to schedule Runnable that get executed later in the IO Thread
Author: normanmaurer
Created: 2012-03-01 06:27:12+00:00
State: open

We now support to submit a Runnable that will get picked up in the next IO-Thread loop. It would also be very useful if a user could just also do something like:

ChannelPipeline.schedule(new Runnable() {.. }, 10, TimeUnit.MINUTES);

This would then make sure that Runnable will get executed after 10 minutes once the next IO-Thread loop kicks in.

I know a user could do something like this by itsown by just doing something like:

ScheduledExecutorService.schedule(new Runnable() {
public void run() {
ChannelPipeline.execute(new Runnable() {..});
}

But I think it would be very nice to hide this stuff from the user and we may also be able to come-up with something better in terms of implementation...