Class AbstractSetupAction
- java.lang.Object
-
- com.opensymphony.xwork2.ActionSupport
-
- com.atlassian.confluence.core.ConfluenceActionSupport
-
- com.atlassian.confluence.setup.actions.AbstractSetupAction
-
- All Implemented Interfaces:
WebInterface
,MessageHolderAware
,com.opensymphony.xwork2.Action
,com.opensymphony.xwork2.interceptor.ValidationAware
,com.opensymphony.xwork2.LocaleProvider
,com.opensymphony.xwork2.TextProvider
,com.opensymphony.xwork2.Validateable
,Serializable
- Direct Known Subclasses:
AbstractConfluenceLicenseAction
,AbstractSetupDatabaseAction
,ConnectToJiraAction
,ConnectToJiraSyncDirectoryAction
,FinishSetupAction
,SelectGlobalLocaleAction
,SelectSetupStepAction
,SetupAdministrator
,SetupClusterAction
,SetupDataAction
,SetupDemoContentAction
,SetupPathsAction
,SetupStartAction
,SetupUserManagementChoiceAction
public abstract class AbstractSetupAction extends ConfluenceActionSupport
This action communicates with BootstrapManager. BootstrapManager remembers state persistence for the setup cycle.All control for setup sequences is, funnily enough, seated in struts.xml (the Controller).
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static String
DEMO_CONTENT_ZIP_FILE
protected static String
SETUP_CLUSTER
protected static String
SETUP_CLUSTER_TO_STANDALONE
protected static String
SETUP_CONTENT_BLANK
protected static String
SETUP_CONTENT_DEMO
protected static String
SETUP_CONTENT_IMPORT
protected static String
SETUP_CUSTOM
protected static String
SETUP_DB_CLUSTER_CONN_TYPE
protected static String
SETUP_DB_CONN_TYPE
protected static String
SETUP_DB_DATASOURCE
protected static String
SETUP_DB_EMBEDDED
protected static String
SETUP_DB_STANDARD
protected static String
SETUP_DB_TYPE_DATASOURCE
protected static String
SETUP_DB_TYPE_STANDARD
protected static String
SETUP_PATHS
protected static String
SETUP_QUICK
protected static String
SETUP_SESSION_ID_KEY
protected static String
SETUP_SKIP_TO_NEXT_STEP
protected static String
SETUP_SKIP_TO_NEXT_STEP_CLUSTER
protected static String
SETUP_USER_INTERNAL
protected static String
SETUP_USER_JAACS
-
Fields inherited from class com.atlassian.confluence.core.ConfluenceActionSupport
accessModeService, CANCEL, DEVMODE, eventManager, i18NBeanFactory, labelManager, languageManager, LICENSE_EXPIRED, LICENSE_USERS_EXCEEDED, messageHolder, permissionManager, permitted, personService, pluginAccessor, PREVIEW, settingsManager, spacePermissionManager, systemInformationService, userAccessor, webInterfaceManager
-
-
Constructor Summary
Constructors Constructor Description AbstractSetupAction()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected BootstrapConfigurer
bootstrapConfigurer()
protected BootstrapManager
getBootstrapManager()
com.atlassian.spring.container.ContainerManager
getContainerManager()
Locale
getLocale()
String
getServerId()
ConfluenceSetupPersister
getSetupPersister()
String
getSetupSessionId()
The following methods are for collecting metadata used for installer analytics (CONFDEV-27425)protected <T> com.atlassian.fugue.Maybe<T>
getSingletonFromMainContext(Class<T> type)
Deprecated.since 7.0.1.String
getSupportEntitlementNumber()
String
getXsrfToken()
com.atlassian.xwork.XsrfTokenGenerator
getXsrfTokenGenerator()
boolean
isPermitted()
override the parent's implementation - everyone is allowed to perform a setup action.protected <T> Optional<T>
retrieveSingletonFromMainContext(Class<T> type)
Retrieves a single bean of the given type from the main context.void
setBootstrapConfigurer(BootstrapConfigurer bootstrapConfigurer)
void
setBootstrapSidManager(ConfluenceSidManager bootstrapSidManager)
void
setContainerManager(com.atlassian.spring.container.ContainerManager containerManager)
void
setLicenseService(LicenseService licenseService)
void
setSetupPersister(ConfluenceSetupPersister setupPersister)
void
setXsrfTokenGenerator(com.atlassian.xwork.XsrfTokenGenerator xsrfTokenGenerator)
protected void
transitionFromColdToTenantedState()
protected void
transitionFromColdToVacantState()
Cold to vacant transition.protected void
transitionFromVacantToTenantedState()
Vacant to tenanted transition.-
Methods inherited from class com.atlassian.confluence.core.ConfluenceActionSupport
addActionError, addActionMessage, addFieldError, addPermissionTypeTo, addToHistory, doDefault, formatFriendlyDate, getAccessMode, getActionName, getActionName, getAuthenticatedUser, getBootstrapStatusProvider, getCancel, getCancelResult, getConfluenceAccessManager, getContentUiSupport, getContext, getCurrentRequest, getCurrentSession, getDateFormatSetting, getDateFormatter, getDefaultResourceBundle, getDefaultTimeZone, getDocBean, getDocLink, getEventManager, getFriendlyDateFormatter, getFrontendServiceURL, getGlobalSettings, getHelper, getI18n, getInstalledLanguages, getLabelManager, getLanguageJs, getLanguageManager, getLanguageUserFriendly, getLocaleManager, getLocaleString, getMessageHolder, getNiceContentType, getPermissionManager, getPermissionTypes, getPermittedEntitiesOf, getPermittedEntitiesOf, getPermittedEntitiesOf, getPersonService, getPreviousLoginDate, getRemoteUser, getSession, getSystemInformationService, getText, getText, getText, getText, getText, getText, getText, getText, getTextStatic, getTextStatic, getTextStrict, getTimeZone, getUserAccessor, getUserByName, getUserFullName, getUserHasBrowseUsersPermission, getUserHasLicensedAccess, getUserInterfaceState, getUserLocaleDefaultDatePattern, getUserProfilePicUrl, getWebInterfaceContext, getWebInterfaceManager, hasPermissionForSpace, isAnonymousUser, isCanceled, isDevMode, isEmailVisible, isExternalUserManagementEnabled, isLabelable, isPrintableVersion, isSkipAccessCheck, isUserStatusPluginEnabled, isUsingH2, isUsingHSQL, setAccessModeService, setApiDateFormatService, setApiPersonService, setBootstrapManager, setCancel, setConfluenceAccessManager, setContentUiSupport, setEventManager, setFormatSettingsManager, setI18NBean, setI18NBeanFactory, setLabelManager, setLanguageManager, setLocaleManager, setLoginManager, setMessageHolder, setPermissionManager, setPluginAccessor, setPreviousLoginDate, setServletRequestSupplier, setSettingsManager, setSpacePermissionManager, setSystemInformationService, setTimeZoneManager, setUserAccessor, setWebInterfaceManager, useSkipAccessCheck, withServletRequestSupplier
-
Methods inherited from class com.opensymphony.xwork2.ActionSupport
addActionError, addActionMessage, addFieldError, clearActionErrors, clearErrors, clearErrorsAndMessages, clearFieldErrors, clearMessages, clone, execute, getActionErrors, getActionMessages, getContainer, getFieldErrors, getFormatted, getLocaleProvider, getText, getText, getTextProvider, getTexts, getTexts, hasActionErrors, hasActionMessages, hasErrors, hasFieldErrors, hasKey, input, isValidLocale, isValidLocaleString, pause, setActionErrors, setActionMessages, setContainer, setFieldErrors, validate
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.opensymphony.xwork2.LocaleProvider
isValidLocale, isValidLocaleString
-
Methods inherited from interface com.atlassian.confluence.validation.MessageHolderAware
validate
-
-
-
-
Field Detail
-
DEMO_CONTENT_ZIP_FILE
public static final String DEMO_CONTENT_ZIP_FILE
- See Also:
- Constant Field Values
-
SETUP_QUICK
protected static final String SETUP_QUICK
- See Also:
- Constant Field Values
-
SETUP_CLUSTER
protected static final String SETUP_CLUSTER
- See Also:
- Constant Field Values
-
SETUP_CUSTOM
protected static final String SETUP_CUSTOM
- See Also:
- Constant Field Values
-
SETUP_CLUSTER_TO_STANDALONE
protected static final String SETUP_CLUSTER_TO_STANDALONE
- See Also:
- Constant Field Values
-
SETUP_USER_INTERNAL
protected static final String SETUP_USER_INTERNAL
- See Also:
- Constant Field Values
-
SETUP_USER_JAACS
protected static final String SETUP_USER_JAACS
- See Also:
- Constant Field Values
-
SETUP_DB_EMBEDDED
protected static final String SETUP_DB_EMBEDDED
- See Also:
- Constant Field Values
-
SETUP_DB_STANDARD
protected static final String SETUP_DB_STANDARD
- See Also:
- Constant Field Values
-
SETUP_DB_DATASOURCE
protected static final String SETUP_DB_DATASOURCE
- See Also:
- Constant Field Values
-
SETUP_DB_CONN_TYPE
protected static final String SETUP_DB_CONN_TYPE
- See Also:
- Constant Field Values
-
SETUP_DB_CLUSTER_CONN_TYPE
protected static final String SETUP_DB_CLUSTER_CONN_TYPE
- See Also:
- Constant Field Values
-
SETUP_DB_TYPE_STANDARD
protected static final String SETUP_DB_TYPE_STANDARD
- See Also:
- Constant Field Values
-
SETUP_DB_TYPE_DATASOURCE
protected static final String SETUP_DB_TYPE_DATASOURCE
- See Also:
- Constant Field Values
-
SETUP_CONTENT_BLANK
protected static final String SETUP_CONTENT_BLANK
- See Also:
- Constant Field Values
-
SETUP_CONTENT_DEMO
protected static final String SETUP_CONTENT_DEMO
- See Also:
- Constant Field Values
-
SETUP_CONTENT_IMPORT
protected static final String SETUP_CONTENT_IMPORT
- See Also:
- Constant Field Values
-
SETUP_SESSION_ID_KEY
protected static final String SETUP_SESSION_ID_KEY
- See Also:
- Constant Field Values
-
SETUP_PATHS
protected static final String SETUP_PATHS
- See Also:
- Constant Field Values
-
SETUP_SKIP_TO_NEXT_STEP
protected static final String SETUP_SKIP_TO_NEXT_STEP
- See Also:
- Constant Field Values
-
SETUP_SKIP_TO_NEXT_STEP_CLUSTER
protected static final String SETUP_SKIP_TO_NEXT_STEP_CLUSTER
- See Also:
- Constant Field Values
-
-
Method Detail
-
setSetupPersister
public void setSetupPersister(ConfluenceSetupPersister setupPersister)
-
getSetupPersister
public ConfluenceSetupPersister getSetupPersister()
-
isPermitted
public boolean isPermitted()
override the parent's implementation - everyone is allowed to perform a setup action.- Overrides:
isPermitted
in classConfluenceActionSupport
- Returns:
- true always
-
getBootstrapManager
protected BootstrapManager getBootstrapManager()
- Overrides:
getBootstrapManager
in classConfluenceActionSupport
-
bootstrapConfigurer
protected BootstrapConfigurer bootstrapConfigurer()
-
getLocale
public Locale getLocale()
- Specified by:
getLocale
in interfacecom.opensymphony.xwork2.LocaleProvider
- Overrides:
getLocale
in classConfluenceActionSupport
-
transitionFromColdToTenantedState
protected void transitionFromColdToTenantedState() throws com.atlassian.config.ConfigurationException
- Throws:
com.atlassian.config.ConfigurationException
-
transitionFromColdToVacantState
protected void transitionFromColdToVacantState() throws com.atlassian.config.ConfigurationException
Cold to vacant transition.The main context is initialized without a configured database connection. Plugins which don't need a tenant on enablement or can react to tenant arrival are loaded.
- Throws:
com.atlassian.config.ConfigurationException
- Since:
- 5.6
- See Also:
SplitStartupPluginSystemLifecycle.earlyStartup()
-
transitionFromVacantToTenantedState
protected void transitionFromVacantToTenantedState()
Vacant to tenanted transition.Called after the database is configured. The (system) tenant is declared as arrived, allowing the initialisation of the session factories, and the plugins which need a tenant on enablement are loaded.
- Since:
- 5.6
- See Also:
SystemTenant.arrived()
,SplitStartupPluginSystemLifecycle.lateStartup()
-
getSingletonFromMainContext
@Deprecated protected <T> com.atlassian.fugue.Maybe<T> getSingletonFromMainContext(Class<T> type)
Deprecated.since 7.0.1. UseretrieveSingletonFromMainContext(Class)
Retrieves a single bean of the given type from the main context.- Type Parameters:
T
- the type of the singleton- Parameters:
type
- the class instance of the type- Returns:
- maybe the singleton
- Since:
- 5.6
-
retrieveSingletonFromMainContext
protected <T> Optional<T> retrieveSingletonFromMainContext(Class<T> type)
Retrieves a single bean of the given type from the main context.- Type Parameters:
T
- the type of the singleton- Parameters:
type
- the class instance of the type- Returns:
- maybe the singleton
- Since:
- 7.0.1
-
getContainerManager
public com.atlassian.spring.container.ContainerManager getContainerManager()
-
setContainerManager
public void setContainerManager(com.atlassian.spring.container.ContainerManager containerManager)
-
getSetupSessionId
public String getSetupSessionId()
The following methods are for collecting metadata used for installer analytics (CONFDEV-27425)
-
setBootstrapSidManager
public void setBootstrapSidManager(ConfluenceSidManager bootstrapSidManager) throws com.atlassian.config.ConfigurationException
- Throws:
com.atlassian.config.ConfigurationException
-
getXsrfToken
public String getXsrfToken()
-
getXsrfTokenGenerator
public com.atlassian.xwork.XsrfTokenGenerator getXsrfTokenGenerator()
-
setXsrfTokenGenerator
public void setXsrfTokenGenerator(com.atlassian.xwork.XsrfTokenGenerator xsrfTokenGenerator)
-
getServerId
public String getServerId()
-
setLicenseService
public void setLicenseService(LicenseService licenseService)
-
getSupportEntitlementNumber
public String getSupportEntitlementNumber()
-
setBootstrapConfigurer
public void setBootstrapConfigurer(BootstrapConfigurer bootstrapConfigurer)
-
-