Forum Discussion
James_Thomson
Employee
Nov 22, 2006Compress if RTT is above a certain amount
I'm trying to use the following iRule:
when HTTP_REQUEST {
set rtt [TCP::rtt]
}
when HTTP_RESPONSE {
if {$rtt < 1600 } {
log "NOcompress rtt=[TCP::rtt]"
COMPRESS::disable
}
...
JRahm
Admin
Nov 27, 2006You are comparing on a stored value from the request, but logging the current value from the response. You could log both values to see if they are different:
when HTTP_REQUEST {
set rtt [TCP::rtt]
}
when HTTP_RESPONSE {
if {$rtt < 1600 } {
log "NOcompress rtt=[TCP::rtt], stored rtt=$rtt"
COMPRESS::disable
}
elseif {$rtt > 1600 } {
log "compress current rtt=[TCP::rtt], stored rtt=$rtt"
COMPRESS::enable
COMPRESS::gzip level 9
}
}
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects