com.atlassian.jira.soy
Class SoyCacheFlusher

java.lang.Object
  extended by com.atlassian.jira.soy.SoyCacheFlusher
All Implemented Interfaces:
org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.InitializingBean

@Component
public class SoyCacheFlusher
extends Object
implements org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.DisposableBean

Capable of flushing a soy cache in a single bound. Temporary measure until Atlassian Cache can coordinate plugin cache flushing.

Since:
v6.1

Constructor Summary
SoyCacheFlusher(com.atlassian.event.api.EventPublisher eventPublisher, com.atlassian.soy.impl.SoyManager soyManager)
           
 
Method Summary
 void afterPropertiesSet()
           
 void destroy()
           
 boolean flushSoyCache()
          Attempts to flush the cache in the SoyManager.
 void onClearCache(ClearCacheEvent event)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SoyCacheFlusher

public SoyCacheFlusher(com.atlassian.event.api.EventPublisher eventPublisher,
                       com.atlassian.soy.impl.SoyManager soyManager)
Method Detail

destroy

public void destroy()
             throws Exception
Specified by:
destroy in interface org.springframework.beans.factory.DisposableBean
Throws:
Exception

afterPropertiesSet

public void afterPropertiesSet()
                        throws Exception
Specified by:
afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
Throws:
Exception

onClearCache

@EventListener
public void onClearCache(ClearCacheEvent event)

flushSoyCache

public boolean flushSoyCache()
Attempts to flush the cache in the SoyManager.

Returns:
true only if the request was successfully sent without exception.


Copyright © 2002-2014 Atlassian. All Rights Reserved.