Skip to content

Commit 00103bd

Browse files
Alex TharpAlex Tharp
Alex Tharp
authored and
Alex Tharp
committed
Merge pull request #18 from cortex-cms/never-expire-cache
Never Expire Cache
2 parents 2b72ce9 + c1064fd commit 00103bd

File tree

3 files changed

+4
-3
lines changed

3 files changed

+4
-3
lines changed

CHANGELOG.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,5 @@ Version History
33
* All Version bumps are required to update this file as well!!
44
----
55

6-
* 0.5.0 - Auto-inject Client Helper into Views/Controllers. Pass through to Snippet tag entire set of HTML attributes. Implement new namespacing and support Bundler.require.
6+
* 0.5.1 - Set Webpage feed cache to never expire
7+
* 0.5.0 - Auto-inject Client Helper into Views/Controllers. Add 10s race condition resolution to Rails cache fetch. Pass through to Snippet tag entire set of HTML attributes. Implement new namespacing and support Bundler.require.

lib/cortex/snippets/client.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ def cortex_client
1818

1919
def current_webpage(request)
2020
if defined?(Rails)
21-
Rails.cache.fetch("webpages/#{request_url(request)}", expires_in: 30.minutes, race_condition_ttl: 10) do
21+
Rails.cache.fetch("webpages/#{request_url(request)}", expires_in: 0, race_condition_ttl: 10) do
2222
cortex_client.webpages.get_feed(request_url(request)).contents
2323
end
2424
else

lib/cortex/snippets/client/version.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
module Cortex
22
module Snippets
33
module Client
4-
VERSION = '0.5.0'
4+
VERSION = '0.5.1'
55
end
66
end
77
end

0 commit comments

Comments
 (0)