JCS is a universal object buffer, Hibernate can use JCS to buffer query results set. If you want to make a buffer for a lasting object, add a line in front of the HBM's Class tag:
Cache.ccf is the JCS configuration file, mainly configured: jcs.default.cacheattributes.MaxObjects = 5000 (buffer accommodation object size) jcs.default.ementattributes.maxlifeseconds = 240 (maximum buffer time) In addition to the entire lasting object, You can buffer the collection attribute of the object, which is OK below in the Property tag. When you read the data for the first time, whether you use List or iterator, you will fill the data into the buffer. If you encounter the same query results, you will not go to the database, but you can take it directly to the JCS buffer, but only Iterator can go buffer. Accommoding data, List always takes directly from the database and cannot utilize buffers.