提高liferay性能

转载自: http://www.liferay.com/web/wanpeng/blog/-/blogs/777189
提高liferay性能

似乎总能听到liferay性能的抱怨, 在一个开源软件中这其实不难理解,就想一台公用的电脑,有人用oracle就在上面装个oracle,有人用DB2就又装了一个DB2…… 这些服务都启动自然就会慢。我们要做的就是停掉一些用不到的功能和方便开发人员debug的一些选项。

  • 启动速度相关参数:
    在不需要自动创建数据库结构的时候可以停掉此项:
#
  # Set this to true to automatically create tables and populate with default
  # data if the database is empty.
  #
  schema.run.enabled=false


      在不需要重新建立luence索引时

##Lucene Search
#Set the following to true if you want to index your entire library of files on startup.
index.on.startup=false

 

  • 提高运行时性能

      开启layout cache

# The layout cache filter will cache pages to speed up page rendering for
# guest users. See ehcache.xml to modify the cache expiration time to live.
com.liferay.portal.servlet.filters.layoutcache.LayoutCacheFilter=true

 

     压缩javascript文件

# Set this property to true to load the combined JavaScript files from the
# property "javascript.files" into one compacted file for faster loading for
# production. Set this property to false for easier debugging for
# development. You can also disable fast loading by setting the URL
# parameter "js_fast_load" to "0".
javascript.fast.load=true

 

     压缩 css 文件

# Set this property to true to load the theme's merged CSS files for faster
# loading for production. Set this property to false for easier debugging
# for development. You can also disable fast loading by setting the URL
# parameter "css_fast_load" to "0".
theme.css.fast.load=true

 

    开启vm模板cache

   # Set this to true in production so that VM templates are cached
  velocity.engine.resource.manager.cache.enabled=true

 

还有一些像auto.deploy.enabled这样的属性在不需要的时候也可以关闭,减少系统扫描的开销。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值