Forum Discussion

James_Thomson's avatar
Dec 10, 2004

mapclass2node

Along the same lines off an an earlier post by Natty about persistence. I'm trying to just read a cookie that is handed out by the server and persist a user on it. One example is where the cookie is static and therefore, I thought of user mapclass2node.

 

 

class nodes {

 

"s1s1 10.11.1.10:80"

 

"s1s2 10.11.1.20:80"

 

}

 

 

I'd like to search the request and map as appropriate. I used to do this in the pool with a select command:

 

select mapclass2node ((http_cookie,("server")),nodes)

 

 

How does this work now? Do I need to do a when HTTP_REQUEST and then some if statement.

 

 

when HTTP_REQUEST {

 

if {HTTP::cookie]} {

 

select mapclass2node((http_cookie,("server")),nodes)

 

}}

15 Replies