Home


10.2.4 Cached page sizes greater than 200Kb

It was discovered during testing that pages constructed by WebSphere Commerce were large and filled with white space. To avoid poor performance, pages are compressed by the Web server prior to transmission to the user's browser.

Unfortunately, the uncompressed pages are stored by DynaCache in the JVM. With up to 3000 cached pages stored, this could take 600Mb of heap memory. Care had to be taken to ensure the maximum heap memory could accommodate this amount of storage.

The initial heap size of the online shop was too small and the JVM would regularly run out of memory during peak loads or abnormal circumstances.

To avoid memory problems, the number of in-memory entries in the cache was reduced to 2000 to provide an appropriate memory buffer. Any entries over 2000 are stored in the disk cache. Only the least recently used cache entries were stored to disk. It was also found to be quicker to restore a cached page from disk than to re-render its contents.

Since making this change, the online shop has run continuously for a month without any restarts or failures.

+

Search Tips   |   Advanced Search