mina-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Scott Peters" <spet...@visto.com>
Subject Traffic Shape Filter
Date Fri, 04 Jan 2008 23:37:00 GMT
Are there any examples of how to use the Traffic Shaping filter?  I do
not see any unit test cases so it brings to question if this filter has
been tested or ready yet?

With this code below I do not see any change in behavior that would show
the throughput is being slowed down.

My goal is to allow us to simulate different network through puts [
GPRS, EDGE, T1, etc ] that different parts of our product use.

<code>
public static ScheduledExecutorService	s_scheduler
Executors.newScheduledThreadPool(Runtime.getRuntime().availableProcessor
s());

Public sessionCreated(IoSession session)
{
	...
	TrafficShapingFilter tsf = new TrafficShapingFilter(s_scheduler,
100, 100);
	session.getFilterChain().addFirst(TRAFFIC_SHAPING_FILTER, tsf);
	...
}
</code>


Thank you,
Scott Peters

Mime
View raw message