Forum Discussion
Ross_79174
Nimbostratus
Mar 11, 2009Help caching urls with unique date/time stamp
Hello irule gurus!
We have an issue on our production service where we need to cache our rss feeds to offload our backend servers. The problem is that each rss url has a unique date/ti...
hoolio
Cirrostratus
Mar 11, 2009Hi Ross,
TMM will crash if you force caching with CACHE::enable and the request does not contain a Host header (not required in HTTP v1.0) or a URI (required in all HTTP versions). This is described in SOL9617 (Click here). So it would be good to add a check for the Host header value and path having a length:
if { [HTTP::uri] starts_with "/rss" && [string length [HTTP::host]] && [string length [HTTP::path]] } {
To parse the portion of the URI you mention in the first post, you can use HTTP::path to get the URI minus the query string and then just the parameter value for oauth_consumer_key
So to get this:
/rss/Pepcom/Pepcom+June+2008?oauth_consumer_key=ced9fcdbcae5bd941f51cf82421e6413
You can use this:
"[HTTP::path]?oauth_consumer_key=[URI::query [HTTP::uri] oauth_consumer_key]"
Lastly, 'persist none' will disable persistence for the duration of the TCP connection. If there are multiple HTTP requests over the same TCP connection, with an RSS request followed by a non-RSS request, the non-RSS request wouldn't be persisted within the gallery pool. You would want to explicitly set persistence for both cases (persist none and persist .
Aaron
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)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
