Class RuntimeVersion

java.lang.Object
com.seeq.utilities.process.RuntimeVersion

public class RuntimeVersion extends Object
This class is used for the discovery of the presently running software's version and buildTime. It leverages the existing Manifest file or the existing Properties file (specified in the constructor).
  • Constructor Details

    • RuntimeVersion

      public RuntimeVersion(Class<?> callingClass)
      Constructor.
      Parameters:
      callingClass - The calling class.
  • Method Details

    • getVersion

      public String getVersion()
      Read the Manifest file or Properties file and extract the version information. The logic behind this method is to use the Build Properties file in the supervisor directory to pull the Seeq non-marketing version number. If the file isn't available, then this will throw an IllegalStateException.
      Returns:
      Version of the running application.
    • getMarketingVersion

      public String getMarketingVersion()
      Read the Manifest file or Properties file and extract the version information. The logic behind this method is to use the Build Properties file in the supervisor directory to pull the Seeq marketing version number. If the file isn't available, then this will throw an IllegalStateException.
      Returns:
      Marketing version of the running application.
    • getBuildTime

      public String getBuildTime()
      Read the Manifest file or Properties file and extract the version build time information. The logic behind this method is that if the Manifest file is not available (probably because we are running from within an IDE), then attempt to get it from the Properties file. If that is not available, then this will throw an IllegalStateException.
      Returns:
      Version build time of the running application.
    • getCommit

      public String getCommit()
    • getManifest

      public Manifest getManifest() throws IOException
      Get a reference to the Manifest file.
      Returns:
      A Manifest instance of the Manifest file.
      Throws:
      IOException - If the manifest information isn't found