Skip to Content

How to configure the cache validity time of files downloaded from KM?

Dear Guru's,

I need your help on the following. We currently have a KM Navigation iView inplace that allows some endusers to download pre-calculated and generated reports that are Zipped from KM.

When clicked on the default browser behaviour is that the browser (MSIE) will confront the user with a popup that allows:

1. Save File to disk

2. Open the File

3. Cancel

This is ok. Most users will click "open the file" this will actually download the file to the "Temporary Internet Files"-folder and then open WinZip on this file. The WinZip dialog then shows the Excel file. This can be opened, saved or whatever...

Here it comes... when the initilal zip file is opened instead of saved to disk then as mentioned it is stored in the temp internet files.

All files stored in temp internet files most of the time have an Expires property set. This is the Cache validity.

But the ZIP file as mentioned in the example doesn't Expire as it is set to not expire at all. This will give unwanted behaviour as the zip files will be refreshed weekly or montly on the KM server and then the when the user wants to get the latest the browser will take the file in the Cache instead of the KM server.

How do I set the cache validity periode for KM files? Or KM in general?

Ansers like:

- Clear Temp Internet files

- Let users always save instead of open

... will not be awarded 😊

Thanks in advance,

Benjamin Houttuin

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    avatar image
    Former Member
    Sep 05, 2008 at 01:23 PM

    First, I'd recommend to check the HTTP caching metadata KM is returning.

    For Firefox, use the LiveHttpHeaders plugin. For IE, try "HTTP Fiddler".

    Best regards, Julian

    Add comment
    10|10000 characters needed characters exceeded

    • All,

      I did a HTTP trace and the result is the following:

      GET /irj/go/km/docs?URI=/irj/go/km/docs/<xxx>/<yyyy>/<zzzz>/<NameOfDocument>.zip&action=download HTTP/1.1
      Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, application/xaml+xml, application/vnd.ms-xpsdocument, application/x-ms-xbap, application/x-ms-application, */*
      Accept-Language: nl,en;q=0.5
      Accept-Encoding: gzip, deflate
      User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30)
      Host: <servername.domain.nl>:<port>
      Connection: Keep-Alive
      Cookie: saplb_*=(J2EE103837300)103837351; PortalAlias=portal; JSESSIONID=(J2EE103837300)ID1509474951DB11028838670351535984End; MYSAPSSO2=AjExMDAgABNwb3J0YWw6VENDX0hPVVRUVUlOiAATYmFzaWNhdXRoZW50aWNhdGlvbgEADFRDQ19IT1VUVFVJTgIAAzAwMAMAA1JCMQQADDIwMDgwOTA4MDYxMgUABAAAAAgKAAxUQ0NfSE9VVFRVSU7%2FAPUwgfIGCSqGSIb3DQEHAqCB5DCB4QIBATELMAkGBSsOAwIaBQAwCwYJKoZIhvcNAQcBMYHBMIG!AgEBMBMwDjEMMAoGA1UEAxMDUkIxAgEAMAkGBSsOAwIaBQCgXTAYBgkqhkiG9w0BCQMxCwYJKoZIhvcNAQcBMBwGCSqGSIb3DQEJBTEPFw0wODA5MDgwNjEyMTFaMCMGCSqGSIb3DQEJBDEWBBRdfwduRgvpi8jd5j11h%2F8RWlX%2FLDAJBgcqhkjOOAQDBC8wLQIVANnaxABttK3TzeVp!wbiAcrCIVnDAhQWyRV43OrQRNv9acXAOM3A9iBm4Q%3D%3D
      
      HTTP/1.1 200 OK
      Server: SAP J2EE Engine/7.00
      Content-Type: application/x-zip-compressed
      Date: Mon, 08 Sep 2008 06:30:20 GMT
      Cache-Control: private
      Content-Disposition: attachment; filename=<NameOfDocument>.zip
      Accept-Ranges: bytes
      ETag: "910533132752"
      Last-Modified: Fri, 01 Aug 2008 10:57:14 GMT
      Content-Length: 1575

      Note that in the respons the "Cache-Control" header field is set to private only there is no info on the livetime like set in the property "max-age=".

      Please advice if you have an idea...

      Thanks,

      Benjamin Houttuin

  • avatar image
    Former Member
    Sep 08, 2008 at 07:16 AM

    1) Can you reproduce this with Firefox?

    2) Did you check the IE settings, on particular the caching behaviour? (as far as I can tell, the HTTP response is totally ok -- in absence of "expiry" information, the browser shouldn't use the cached version).

    Add comment
    10|10000 characters needed characters exceeded