CCA Parser errors with a value containing newlines


Article ID: 126338


Updated On:




Parsing a name value file that has the value that contains newlines, the parser will error out with the following in the cca.log: ( - parser error: line ### column ## text [
] (syntax error) ( - File cant be parsed... Parser: Lexer:

The format of a typical name-value is :
myName = myValue

The wrapping of a newline would show:
myName = myValue1,



This has been seen in the file on Redhat, but can also apply to other similar formations


In the OOTB Redhat Blueprint (Red hat Enterprise Linux Server), the Configuration --> File Parsing --> has the structure class set to "RHEL Configuration Files v2".
  1. In order to make any changes to the OOTB Blueprints, you need to make a copy of it and modify the copy (optionally, disable the OOTB blueprint to avoid a double discovery)
  2. Once the copy is made, go to Blueprints --> Structure Classes and find "RHEL Configuration Files v2".  Checkbox it and do "Select Actions" --> "Copy Structure Class" --> name it as you please
  3. Modify that Structure class to change the parser from "Generic Name-Value Configuration" to "Apache HTTP Configuration Parser"
  4. Save the Structure
  5. Proceed back to the newly copied blueprint -->  Configuration --> File Parsing -->
  6. Change the structure class from "RHEL Configuration Files v2" to the newly named one you created
  7. Save the setting