cancel
Showing results for 
Search instead for 
Did you mean: 

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

benjamin_houttuin
Active Contributor
0 Kudos

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

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

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

benjamin_houttuin
Active Contributor
0 Kudos

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

Answers (1)

Answers (1)

Former Member
0 Kudos

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).

benjamin_houttuin
Active Contributor
0 Kudos

Thanx for thinking with me but I Already found the solution myself :$

Its 1 of the configurable elements in the 100000 KM parameters that are there....

Called: "Client-Side Caching of Static Objects"

Link: http://help.sap.com/saphelp_nw70/helpdata/en/45/7c6336b6e5694ee10000000a155369/frameset.htm

Again thnx,

Benjamin Houttuin