I plan to rewrite my logging filter to update an application scoped map,
aggregating response sizes for a given user. However I would probably
use EhCache (which works as a map, ram or disk based and can persist
between restarts) not to burden a database. If you come up with
something Dário, I'd love to see a post about it here on the list. :)
Regards,
Casper
Paul Sandoz wrote:
> Hi Dário,
>
> I do not have any experience in this area.
>
> I suppose you could write a Jersey request filter to do such rate
> limiting. It should be rather easy, the devil is in the details of
> where/how the information is stored.
>
> But perhaps web front end servers and routing hardware may also be
> able to perform such functionality before it reaches the application?
>
> Paul.
>
> On Feb 15, 2010, at 12:58 PM, Dário Abdulrehman wrote:
>
>> What is the recommended approach for rate limiting web services?
>> Does Jersey support this?
>> Two approaches come to my mind: at the application level, using a
>> relation of IP, timestamp and number of calls, which is used to
>> register for each IP, the number of calls made in a 24 hour period.
>> This count is reset every 24 hours. The other approach is at the OS
>> level using for example iptables (UNIX).
>>
>> Thanks.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jersey.dev.java.net
> For additional commands, e-mail: users-help_at_jersey.dev.java.net
>