Class Installation


  • public final class Installation
    extends Object
    Class to be used by client tools to retrieve install and instance paths.
    • Field Detail

      • WINDOWS_BINARIES_DIR_NAME

        public static final String WINDOWS_BINARIES_DIR_NAME
        Windows binaries (batch files) directory name.
        See Also:
        Constant Field Values
      • UNIX_BINARIES_DIR_NAME

        public static final String UNIX_BINARIES_DIR_NAME
        UNIX binaries (scripts) directory name.
        See Also:
        Constant Field Values
      • LEGAL_NOTICES_DIR_NAME

        public static final String LEGAL_NOTICES_DIR_NAME
        The Legal folder which contains license file.
        See Also:
        Constant Field Values
      • ADMIN_BACKEND_DIR_NAME

        public static final String ADMIN_BACKEND_DIR_NAME
        The admin backend directory name.
        See Also:
        Constant Field Values
      • PROFILES_VERSION_FILE_RELATIVE_PATH

        public static final Path PROFILES_VERSION_FILE_RELATIVE_PATH
        The profiles version file relative path.
      • ADMIN_BACKEND_FILE_NAME

        public static final String ADMIN_BACKEND_FILE_NAME
        The admin data LDIF backend file name.
        See Also:
        Constant Field Values
      • ACCEPTED_LICENSE_FILE_NAME

        public static final String ACCEPTED_LICENSE_FILE_NAME
        The accepted license file name.
        See Also:
        Constant Field Values
      • MAC_JAVA_APP_STUB_NAME_FILE_NAME

        public static final String MAC_JAVA_APP_STUB_NAME_FILE_NAME
        The universal Java application stub file name.
        See Also:
        Constant Field Values
      • SETUP_TOOL_NAME

        public static final String SETUP_TOOL_NAME
        Platform independent name of the setup tool.
        See Also:
        Constant Field Values
      • SETUP_PROFILES_DIR_NAME

        public static final String SETUP_PROFILES_DIR_NAME
        The directory containing setup profiles.
        See Also:
        Constant Field Values
      • START_DS_TOOL_NAME

        public static final String START_DS_TOOL_NAME
        Platform independent name of the start-ds tool.
        See Also:
        Constant Field Values
      • STATUS_TOOL_NAME

        public static final String STATUS_TOOL_NAME
        Platform independent name of the status tool.
        See Also:
        Constant Field Values
      • UPGRADE_TOOL_NAME

        public static final String UPGRADE_TOOL_NAME
        Platform independent name of the upgrade tool.
        See Also:
        Constant Field Values
      • INSTALL_ROOT_SYSTEM_PROPERTY

        public static final String INSTALL_ROOT_SYSTEM_PROPERTY
        The system property used to specify opendj archive root path.
        See Also:
        Constant Field Values
      • CONFIG_FILE_RELATIVE_PATH

        public static final Path CONFIG_FILE_RELATIVE_PATH
        Relative Path to the OpenDJ instance of the config/config.ldif directory.
    • Method Detail

      • installPath

        public static Path installPath()
        Returns the server's installation path.
        Returns:
        The server's installation path.
      • instancePath

        public static Path instancePath()
        Returns the instance root directory (the path where the instance is installed).
        Returns:
        the instance root directory (the path where the instance is installed).
      • instanceConfigFilePath

        public static Path instanceConfigFilePath()
        Returns a Path to the server instance config.ldif file.
        Returns:
        a Path to the server instance config.ldif file.
      • getInstancePathFromInstallPath

        public static Path getInstancePathFromInstallPath​(Path installPath)
        Returns the Path of the instance of the server contained in the provided server installation path.

        If the server is not setup, or does not run in split install/instance mode, then this method returns null.

        Parameters:
        installPath - The installation path
        Returns:
        The path of the server instance ran by the provided server installation path or null, if there is no server has been setup from this installation path or if the server has not been setup in split install/instance mode.
      • getToolPath

        public static Path getToolPath​(String toolName)
        Returns the provided tool path according to the running operating system.
        Parameters:
        toolName - The name of the tool to run (without any extension)
        Returns:
        The absolute path to the tool script
      • getToolPath

        public static Path getToolPath​(Path archivePath,
                                       String toolName)
        Returns the provided tool path according to the running operating system and the provided archive path.
        Parameters:
        archivePath - The OpenDJ exploded archive root path
        toolName - The name of the tool to run (without any extension)
        Returns:
        The absolute path to the tool script
      • getToolName

        public static String getToolName​(String toolName)
        Returns the provided tool name according to the running operating system.
        Parameters:
        toolName - The name of the tool to run (without any extension)
        Returns:
        The filename to use to access the tool