com.atlassian.jira.startup
Class JiraHomeStartupCheck

java.lang.Object
  extended by com.atlassian.jira.startup.JiraHomeStartupCheck
All Implemented Interfaces:
StartupCheck

public class JiraHomeStartupCheck
extends Object
implements StartupCheck

This StartupCheck will check that there is a valid jira.home configured that we can get an exclusive lock on.

Note: this has the side effect that the jira.home directory is created, if required, and "locked". These side-effects are REQUIRED in order to return valid results.

Since:
v4.0

Constructor Summary
JiraHomeStartupCheck(JiraHomePathLocator locator)
           
 
Method Summary
 String getFaultDescription()
          Implement this method to return the description of the fault.
 String getHTMLFaultDescription()
          Implement this method to return the error message of the fault.
static JiraHomeStartupCheck getInstance()
           
 File getJiraHomeDirectory()
           
 String getName()
          Implement this method to return the name of this check
 boolean isInitialised()
           
 boolean isOk()
          Implement this method to return true if the check is positive and false in the case of negative result.
 void stop()
          Called when the tenant / instance is coming down
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

JiraHomeStartupCheck

public JiraHomeStartupCheck(JiraHomePathLocator locator)
Method Detail

getInstance

public static JiraHomeStartupCheck getInstance()

getName

public String getName()
Description copied from interface: StartupCheck
Implement this method to return the name of this check

Specified by:
getName in interface StartupCheck
Returns:
name

isOk

public boolean isOk()
Description copied from interface: StartupCheck
Implement this method to return true if the check is positive and false in the case of negative result.

Specified by:
isOk in interface StartupCheck
Returns:
true if positive

isInitialised

public boolean isInitialised()

stop

public void stop()
Description copied from interface: StartupCheck
Called when the tenant / instance is coming down

Specified by:
stop in interface StartupCheck

getFaultDescription

public String getFaultDescription()
Description copied from interface: StartupCheck
Implement this method to return the description of the fault. This method should return null in the case the check was positive. This message is used to present the user with a message to the console

Specified by:
getFaultDescription in interface StartupCheck
Returns:
fault description

getHTMLFaultDescription

public String getHTMLFaultDescription()
Description copied from interface: StartupCheck
Implement this method to return the error message of the fault. This method should return null in the case the check was positive. This message is used to present the user with a message viewable in a web browser.

Specified by:
getHTMLFaultDescription in interface StartupCheck
Returns:
HTML formatted fault description

getJiraHomeDirectory

public File getJiraHomeDirectory()

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2002-2013 Atlassian. All Rights Reserved.