Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

cacheConfig -> config changes to sync with core plugin; also removed …

…redundant doWithApplicationContext logic
  • Loading branch information...
commit 34b1afbb63f3cf051a94394ba5a963f7a1ef3360 1 parent 48e9099
Burt Beckwith authored
22 CacheRedisGrailsPlugin.groovy
View
@@ -127,28 +127,6 @@ class CacheRedisGrailsPlugin {
}
}
- def doWithApplicationContext = { ctx ->
-
- def cacheConfig = application.config.grails.cache
-
- // TODO hard-coding from the core plugin for now
- def configuredCacheNames = ['grailsBlocksCache', 'grailsTemplatesCache']
- if (cacheConfig.config instanceof Closure) {
- // reusing the builder from the core plugin since there's no configurability yet
- ConfigBuilder builder = new ConfigBuilder()
- builder.parse cacheConfig.config
- configuredCacheNames.addAll builder.cacheNames
- }
-
- // just calling getCache() here to make sure all of the caches exist at startup
- def cacheManager = ctx.grailsCacheManager
- for (String name in configuredCacheNames) {
- cacheManager.getCache name
- }
-
- log.debug "Configured caches: $cacheManager.cacheNames"
- }
-
private boolean isEnabled(GrailsApplication application) {
// TODO
true
2  grails-app/conf/TestCacheConfig.groovy
View
@@ -1,4 +1,4 @@
-cacheConfig = {
+config = {
cache {
name 'basic'
eternal false
2  src/java/grails/plugin/cache/redis/GrailsRedisCache.java
View
@@ -72,7 +72,7 @@ public String getName() {
/**
* {@inheritDoc}
- *
+ *
* This implementation simply returns the RedisTemplate used for configuring
* the cache, giving access to the underlying Redis store.
*/
3  src/java/grails/plugin/cache/web/filter/redis/GrailsSerializer.java
View
@@ -21,6 +21,9 @@
import org.springframework.core.serializer.Serializer;
+/**
+ * @author Burt Beckwith
+ */
public class GrailsSerializer implements Serializer<Object> {
public void serialize(Object object, OutputStream outputStream) throws IOException {
Please sign in to comment.
Something went wrong with that request. Please try again.