consider increasing the maximum size of the cache

来源:互联网 发布:windows10仿mac主题 编辑:程序博客网 时间:2024/05/25 23:16

需要耐心啊,太急于求成,希望直接就得到解决方法了...以至于正确方法都已经出现了,我却没有耐心看下去,所以反而又耽误了不少时间....

项目加载100+张图片,还有一个小的MP4,所以console警告缓存不够

org.apache.catalina.webresources.Cache.getResource Unable to add the resource at [/base/1325/WA6144-150x112.jpg] to the cache because there was insufficient free space available after evicting expired cache entries - consider increasing the maximum size of the cache

The background cache eviction process was unable to free [10] percent of the cache for Context [/liuda] - consider increasing the maximum size of the cache. After eviction approximately [11,145] KB of data remained in the cache

反正就是缓存不够了

http://stackoverflow.com/questions/26893297/tomcat-8-throwing-org-apache-catalina-webresources-cache-getresource-unable-to

上面链接是stackoverflow上出现的和我一样的错误,第二个答案成功的解决了这个警告,就是把缓存弄大点。一开始没耐心看答案,直接把代码加进server.xml了,正确的应该是加到context.xml

<Resources cachingAllowed="true" cacheMaxSize="100000" />


0 0
原创粉丝点击