Re: Rate limiting SOAP transactions

"Owen Garrett" <[email protected]>
Newsgroups gmane.comp.programming.load-balancing.general
Message-ID <[email protected]>
> I am looking for a way to rate limit how many SOAP transactions per
second that a given 
> customer can send us such that any given customer could not overload
the system and cause 
> impact to other customers.

Eric,

This is certainly possible with ZXTM, Zeus' software load balancer /
ADC.

ZXTM has a rules language called 'TrafficScript', quite similar in
capabilities to F5's iRules.  ZXTM's rate shaping capability does
exactly what you need, queuing events that exceed the rate limit so that
they are paused and admitted in following seconds (or minutes).

Here's a couple of examples of rate shaping in action:

http://knowledgehub.zeus.com/articles/2007/02/06/the_contact_us_attack_a
gainst_mail_serve
http://knowledgehub.zeus.com/articles/2006/12/11/zxtm_spider_catcher

For your use case, you may wish to rate-limit by source IP address (to
identify the customer), or perhaps by a unique ID in the SOAP request
that you can extract using an XPath query:

$id = request.getRemoteIP();

... or...

$body = http.getRequestBody();
$id = xml.xpath.matchNodeSet( $body, "", "//userName/text()" );

... then apply a rate class as follows:

rate.use( "SOAP limit", $id );

If the 'SOAP limit' rate class is configured to admit 500 events per
second, then each unique $id will be allowed to perform 500 events /
second; additional events will be queued.

Use rate.getBacklog() to query the queue size and send a SOAP server
fault response (or a 503 Too Busy response) if the queue of events is
too large and you want to discard the connection rather than queuing it.

Regards,

Owen

----
Owen Garrett <[email protected]>
Product Management, Zeus Technology, http://www.zeus.com/
_______________________________________________
lb-l mailing list
[email protected]
http://vegan.net/mailman/listinfo/lb-l
Searchable Archive: http://vegan.net/lb/archive
http://lbdigest.com Load Balancing Digest
http://lbwiki.com Load Balancing Wiki
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.