forked from Archives/Athou_commafeed
cache tweaks
This commit is contained in:
@@ -1,13 +1,19 @@
|
||||
package com.commafeed.backend.model;
|
||||
|
||||
import javax.persistence.Cacheable;
|
||||
import javax.persistence.Column;
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.Lob;
|
||||
import javax.persistence.Table;
|
||||
|
||||
import org.hibernate.annotations.Cache;
|
||||
import org.hibernate.annotations.CacheConcurrencyStrategy;
|
||||
|
||||
@Entity
|
||||
@Table(name = "FEEDENTRYCONTENTS")
|
||||
@SuppressWarnings("serial")
|
||||
@Cacheable
|
||||
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
|
||||
public class FeedEntryContent extends AbstractModel {
|
||||
|
||||
@Column(length = 2048)
|
||||
|
||||
@@ -5,17 +5,17 @@
|
||||
|
||||
<diskStore path="java.io.tmpdir" />
|
||||
|
||||
<defaultCache maxEntriesLocalHeap="10000" eternal="false"
|
||||
<defaultCache maxEntriesLocalHeap="1000000" eternal="false"
|
||||
timeToIdleSeconds="120" timeToLiveSeconds="120" maxEntriesLocalDisk="10000000"
|
||||
diskExpiryThreadIntervalSeconds="120" memoryStoreEvictionPolicy="LRU">
|
||||
<persistence strategy="localTempSwap" />
|
||||
</defaultCache>
|
||||
<!--
|
||||
<cache name="com.commafeed.backend.model.Feed"
|
||||
maxEntriesLocalHeap="100000" maxEntriesLocalDisk="1000" eternal="false"
|
||||
diskSpoolBufferSizeMB="20" timeToIdleSeconds="300" timeToLiveSeconds="600"
|
||||
memoryStoreEvictionPolicy="LFU" transactionalMode="off">
|
||||
|
||||
<cache name="com.commafeed.backend.model.FeedEntryContent"
|
||||
maxEntriesLocalHeap="1000" eternal="false" timeToIdleSeconds="120"
|
||||
timeToLiveSeconds="120" maxEntriesLocalDisk="100000"
|
||||
diskExpiryThreadIntervalSeconds="120" memoryStoreEvictionPolicy="LRU">
|
||||
<persistence strategy="localTempSwap" />
|
||||
</cache>
|
||||
-->
|
||||
|
||||
</ehcache>
|
||||
Reference in New Issue
Block a user