Class AbstractLifecycleHook

java.lang.Object
org.craftercms.deployer.impl.lifecycle.AbstractLifecycleHook
All Implemented Interfaces:
TargetLifecycleHook, InitializableByConfigBean
Direct Known Subclasses:
AbstractIndexAwareLifecycleHook, ClearS3BucketLifecycleHook, CreateCloudFormationLifecycleHook, DeleteCloudFormationLifecycleHook, DeleteLocalRepoFolderLifecycleHook, WaitTillCloudFormationStackUsableLifecycleHook

public abstract class AbstractLifecycleHook extends Object implements TargetLifecycleHook
Base implementation of TargetLifecycleHook
Since:
3.1.8
Author:
joseross
  • Field Details

    • CONFIG_KEY_DISABLED

      public static final String CONFIG_KEY_DISABLED
      See Also:
    • logger

      protected org.slf4j.Logger logger
    • disabled

      protected boolean disabled
  • Constructor Details

    • AbstractLifecycleHook

      public AbstractLifecycleHook()
  • Method Details

    • init

      public void init(org.apache.commons.configuration2.Configuration config) throws org.craftercms.commons.config.ConfigurationException, DeployerException
      Description copied from interface: InitializableByConfigBean
      Initializes the bean using the specified configuration.
      Specified by:
      init in interface InitializableByConfigBean
      Parameters:
      config - the bean's configuration
      Throws:
      org.craftercms.commons.config.ConfigurationException - if there's configuration related exception
      DeployerException - if there's a general exception on init
    • doInit

      protected abstract void doInit(org.apache.commons.configuration2.Configuration config) throws org.craftercms.commons.config.ConfigurationException, DeployerException
      Throws:
      org.craftercms.commons.config.ConfigurationException
      DeployerException
    • execute

      public void execute(Target target) throws DeployerException
      Description copied from interface: TargetLifecycleHook
      Execute the hook.
      Specified by:
      execute in interface TargetLifecycleHook
      Parameters:
      target - the target associated to the hook
      Throws:
      DeployerException - if there's an exception on execution
    • doExecute

      protected abstract void doExecute(Target target) throws DeployerException
      Throws:
      DeployerException