QuestionQ39

VerifiedIdentify and Resolve LTM Device Issues

A virtual server for a group of web services has been configured on an LTM device. The LTM Specialist created an iRule and assigned it to the virtual server:

when HTTP_REQUEST \{  
    switch [HTTP::uri] \{  
        "/WS1/ws.jsp" \{  
            log local0. "[HTTP::uri]-Redirected to JSP Pool"  
            pool JSP  
        \}  
        default \{  
            log local0. "[HTTP::uri]-Redirected to Non-JSP Pool"  
            pool NonJSP  
        \}  
    \}  
\}  

However, the iRule is NOT operating as expected. The following log snapshot is shown:

/WS1/ws.jsp-Redirected to JSP Pool  
/WS1/ws.jsp-Redirected to JSP Pool  
/WS1/ws.jsp-Redirected to JSP Pool  
/WS1/WS.jsp-Redirected to Non-JSP Pool  
/ws1/WS.jsp-Redirected to Non-JSP Pool  
/WS1/ws.jsp-Redirected to JSP Pool  
/ws1/ws.jsp-Redirected to Non-JSP Pool  

What is the issue?

Explanation

The switch comparison against HTTP::uri is case-sensitive, so only the exact string /WS1/ws.jsp matches the JSP-pool branch. URI values with different capitalization fall through to default; case-insensitive routing would require normalizing the URI, such as with string tolower, or otherwise using case-insensitive matching.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!