Class V4Install

    • Constructor Detail

      • V4Install

        public V4Install​(@Nonnull
                         InstallerProperties props,
                         @Nonnull
                         CurrentInstallState installState)
        Constructor.
        Parameters:
        props - The properties to drive the installs.
        installState - The current install.
    • Method Detail

      • execute

        public void execute()
                     throws org.apache.tools.ant.BuildException
        Method to do the work. It assumes that the distribution has been copied.
        Throws:
        org.apache.tools.ant.BuildException - if unexpected badness occurs.
      • checkPreConditions

        protected void checkPreConditions()
                                   throws org.apache.tools.ant.BuildException
        Check for any preconditions to the install.
        Throws:
        org.apache.tools.ant.BuildException - if one is broken.
      • handleVersioning

        protected void handleVersioning()
                                 throws org.apache.tools.ant.BuildException
        Report the to be installed and (if there is one) current versions. Write to be installed version to the dist folder.
        Throws:
        org.apache.tools.ant.BuildException - if the write fails
      • createUserDirectories

        protected void createUserDirectories()
                                      throws org.apache.tools.ant.BuildException
        Create (if they do not exist) the user editable folders, suitable for later population during update or install.
        Throws:
        org.apache.tools.ant.BuildException - if badness occurs
      • getIdPReplacements

        private Properties getIdPReplacements​(boolean sealerCreated)
        Create the properties we need to replace when we merge idp.properties.
        Parameters:
        sealerCreated - have we just created a sealer
        Returns:
        what we need to replace
      • populatePropertyFiles

        protected void populatePropertyFiles​(boolean sealerCreated)
                                      throws org.apache.tools.ant.BuildException
        Create (if they do not exist) propertyFiles. (idp.properties, ldap.properties). This *MUST* happen before populateUserDirectories() or it will not be effective. Note that in V3 serice.properties and nameid.properties but we do not any more.
        Parameters:
        sealerCreated - have we just created a sealer
        Throws:
        org.apache.tools.ant.BuildException - if badness occurs
      • handleEditWebApp

        protected void handleEditWebApp()
                                 throws org.apache.tools.ant.BuildException
        Create and populate (if it does not exist) edit-webapp.
        Throws:
        org.apache.tools.ant.BuildException - if badness occurs
      • checkWebXml

        private void checkWebXml​(Path webXml)
                          throws org.apache.tools.ant.BuildException
        If it exists check web.xml for deprecated content.
        Parameters:
        webXml - the path of the file We do this in a very simplistic fashion at first
        Throws:
        org.apache.tools.ant.BuildException - if we have problems handling the web.xml file
      • populateUserDirectories

        protected void populateUserDirectories()
                                        throws org.apache.tools.ant.BuildException
        Create and populate (if they not exist) the "user visible" folders. (conf, flows, messages, views, logs)
        Throws:
        org.apache.tools.ant.BuildException - if badness occurs
      • enableModules

        protected void enableModules()
                              throws org.apache.tools.ant.BuildException
        ReEnable modules which were already enabled.
        Throws:
        org.apache.tools.ant.BuildException - if badness occurs
      • deleteSpuriousFiles

        protected void deleteSpuriousFiles()
                                    throws org.apache.tools.ant.BuildException
        Delete those files which were created but not needed.
        Throws:
        org.apache.tools.ant.BuildException - if badness occurs
      • generateMetadata

        protected void generateMetadata()
                                 throws org.apache.tools.ant.BuildException
        Create and populate (if it does not exist) the "metadata/idp-metadata.xml" file.
        Throws:
        org.apache.tools.ant.BuildException - if badness occurs
      • reprotect

        protected void reprotect()
                          throws org.apache.tools.ant.BuildException
        Set the protection on the files.
        Throws:
        org.apache.tools.ant.BuildException - if badness occurs