On Wed, Jan 29, 2014 at 10:23 AM, jeremy duvauchelle
<[email protected]> wrote:
> Thanks  for you response
> sorry for my english

no worries about that!

> Our website will be shown on TV ,  the site will grow from 4 simultaneous
> users over 40,000.

This is where HAProxy makes sense.

> we want limited time for users allowed . it was found that in the average
> purchase time was 20-30 minutes.

What you could do easily in HAProxy is to give an inactivity timeout
for an information related to a client stored in a stick-table.
You can also count the number of entries in a stick table and prevent
users to come in if the number of users has been reached.

> I will use something like this
> #Always allow callback from payment gateway
> acl whitelist path_end panier.php

This can be done, of course.

>
> thanks
> can i speak french ?

nope, this is an english ML, even if some of us are French :)

Some times ago, I wrote this article where you may find some useful information:
http://blog.exceliance.fr/2012/09/19/application-delivery-controller-and-ecommerce-websites/

Baptiste

>
>
>
>
>
> 2014-01-29 Baptiste <[email protected]>
>
>> Hi Jeremy,
>>
>> Can you explain us the relation between cookie and the 20 minutes ???
>> Other question: imagine, I'm browsing your website for 20 minutes with
>> something in my trolley, do you want to shut my session and prevent me
>> to buy something on your website?
>>
>> Baptiste
>>
>>
>> On Wed, Jan 29, 2014 at 10:03 AM, jeremy duvauchelle
>> <[email protected]> wrote:
>> >
>> > Hello,
>> > I would like to limit the number of simultaneously connected person on
>> > an
>> > online shop, to keep a certain "site reactivity."
>> >
>> > I am inspired by the configuration:
>> >
>> > http://fotoarkiv.com/wordpress/limiting-the-number-of-active-users-on-a-site-using-haproxy/
>> >
>> > but I have a problem I can not use cookies, because we want the users do
>> > not
>> > stay more than 20 minutes
>> > I would like haproxy looks in the table sesssions, and redirects users
>> > only
>> > present in the list.
>> >
>> > I tried different conditions, but it does not work, it provided to check
>> > if
>> > the IP happens is present in the table (http)
>> > of "stickies sessions"?
>> >
>> > This is a version of "demonstration" with a limited one person to test
>> > easily!
>> >
>> >
>> > =======================8<=====================================================
>> > #The frontend config:
>> > frontend http
>> > bind *:80
>> >
>> > stick-table type ip size 1 expire 1m store gpc0
>> >
>> > #use_backend newuser if { table_avl(http) ge 1 }
>> > #use_backend allowed if { src_get_gpc0(http) gt 0 }
>> > use_backend allowed if { src_conn_cur(http) gt 0 }
>> > #use_backend allowed if { src_conn_cnt(http) gt 0 }
>> > #use_backend allowed if { src_conn_rate(http) gt 0 }
>> > #use_backend allowed if { src_http_req_cnt(http) gt 0 }
>> > #use_backend allowed if { src_http_req_rate(http) gt 0 }
>> >
>> > acl allowed_new table_avl(http) ge 1
>> > use_backend newuser if allowed_new
>> >
>> > default_backend static
>> >
>> >
>> > backend newuser
>> > stick store-request src table http
>> > server marchand_website_new_user XXXXXXXX:80 maxconn 1
>> >
>> >
>> > backend allowed
>> > stick store-request src table http
>> > server marchand_website_allowed XXXXXXXXXXXX:80 maxconn 1
>> >
>> >
>> > backend static
>> > server statique_website  XXXXXXXXXXXX:80 maxconn 1
>> >
>> >
>> > ==================================<8============================================
>> >
>> >
>> > I have the table (http) that fills, but on the second pass I am
>> > redirected
>> > to the static:
>> >
>> > Every 2,0s: echo show table http  | socat /var/run/...  Wed Jan 29
>> > 09:49:55
>> > 2014
>> >
>> > # table: http, type: ip, size:1, used:1
>> > 0x24b52c8: key=80.215.192.123 use=0 exp=48378 server_id=1 gpc0=0
>> >
>> >
>> > Thanks
>> >
>> > I'll try with headers, but I want to understand what I did not
>> > understand
>> >
>> >
>> >
>> >
>
>

Reply via email to