forked from jeremyevans/sequel
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support :frozen=>false option in static_cache plugin, for having new …
…instances returned instead of frozen cached instances This is designed to work with the new pg_static_cache_updater extension, allowing for normal model creates, updates, and deletes, with the updater taking care of updating the cache. By default, automatically update the class by default when using the model instance API to save or destroy objects. But allow that to be disabled via :reload_hooks=>false, so that when using the pg_static_cache_updater, you don't reload the cache twice. Disallow saving/destroying existing instances when the plugin is used without :frozen=>false. This isn't backwards compatible, but was the original intention. In most cases this doesn't change behavior, as existing objects in the cache were frozen and saving/destroying them was disallowed anyway.
- Loading branch information
1 parent
09a616c
commit fc38aae
Showing
3 changed files
with
479 additions
and
181 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.