aboutsummaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorAlex Legler <alex@a3li.li>2016-08-10 12:57:20 +0200
committerAlex Legler <alex@a3li.li>2016-08-10 12:57:20 +0200
commit29e0977d7c31291e0c6382171adce91e465ac3bf (patch)
treea72244128132b6c205715cac3024ca215512ee0f /app
parentDon't cache package header (diff)
downloadpackages-29e0977d7c31291e0c6382171adce91e465ac3bf.tar.gz
packages-29e0977d7c31291e0c6382171adce91e465ac3bf.tar.bz2
packages-29e0977d7c31291e0c6382171adce91e465ac3bf.zip
Manually expire changelog cache
This should hopefully relieve the load the repeated `git log' calls cause.
Diffstat (limited to 'app')
-rw-r--r--app/controllers/packages_controller.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/controllers/packages_controller.rb b/app/controllers/packages_controller.rb
index ee098ae..a972fcd 100644
--- a/app/controllers/packages_controller.rb
+++ b/app/controllers/packages_controller.rb
@@ -35,7 +35,7 @@ class PackagesController < ApplicationController
@package = Package.find_by(:atom, params[:id])
fail ActionController::RoutingError, 'No such package' unless @package
- @changelog = Rails.cache.fetch("changelog/#{@package.atom}", expires_in: 10.minutes) do
+ @changelog = Rails.cache.fetch("changelog/#{@package.atom}") do
Portage::Util::History.for(@package.category, @package.name, 5)
end