Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-7009

Installer prints exception stacktrace to terminal when settings.xml validation fails

XMLWordPrintable

      When user tries to select invalid settings.xml for quickstarts repository, error stacktrace is printed into terminal in both GUI and CLI mode

      CLI example:

      Choose the Maven settings.xml file to use for the above repository:
      0  [x] The default Maven settings.xml located in the /tmp/b/.m2 directory.
      1  [ ] Specify an alternative path to the Maven settings.xml file.
      Input Selection: 
      1
      Choose the Maven settings.xml file to use for the above repository: [/tmp/b/.m2/settings.xml] 
      /tmp/a/EAP-7.1.0/version.txt
      [Fatal Error] version.txt:1:1: Content is not allowed in prolog.
      org.xml.sax.SAXParseException; systemId: file:/tmp/a/EAP-7.1.0/version.txt; lineNumber: 1; columnNumber: 1; Content is not allowed in prolog.
      	at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:257)
      	at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:339)
      	at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:205)
      	at com.redhat.installer.installation.maven.validator.MavenSchemaValidator.determineSettingsVersion(MavenSchemaValidator.java:70)
      	at com.redhat.installer.installation.maven.validator.MavenSchemaValidator.validate(MavenSchemaValidator.java:45)
      	at com.izforge.izpack.panels.StringInputProcessingClient.validate(StringInputProcessingClient.java:86)
      	at com.izforge.izpack.panels.UserInputPanelConsoleHelper.processTextField(UserInputPanelConsoleHelper.java:1045)
      	at com.izforge.izpack.panels.UserInputPanelConsoleHelper.runConsole(UserInputPanelConsoleHelper.java:406)
      	at com.izforge.izpack.panels.UserInputPanelConsoleHelper.runConsole(UserInputPanelConsoleHelper.java:429)
      	at com.izforge.izpack.installer.ConsoleInstaller.iterateAndPerformAction(ConsoleInstaller.java:285)
      	at com.izforge.izpack.installer.ConsoleInstaller.doInstall(ConsoleInstaller.java:640)
      	at com.izforge.izpack.installer.ConsoleInstaller.run(ConsoleInstaller.java:778)
      	at com.izforge.izpack.installer.Installer.main(Installer.java:179)
      Validation error: 
      The provided settings.xml does not pass schema validation.
      Choose the Maven settings.xml file to use for the above repository: [/tmp/b/.m2/settings.xml] 
      

      Expected results CLI:

      Choose the Maven settings.xml file to use for the above repository: [/tmp/b/.m2/settings.xml] 
      /tmp/a/EAP-7.1.0/version.txt
      Validation error: 
      The provided settings.xml does not pass schema validation.
      Choose the Maven settings.xml file to use for the above repository: [/tmp/b/.m2/settings.xml] 
      

      Expected results GUI:
      Warning dialog is shown with "The provided settings.xml does not pass schema validation." and no output in terminal.

              jianajavier Jiana Javier (Inactive)
              jbliznak@redhat.com Jan Blizňák
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: