Uploaded image for project: 'Metron (Retired)'
  1. Metron (Retired)
  2. METRON-1877

Nested IF ELSE statements can cause parse errors in Stellar

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Done
    • Major
    • Resolution: Done
    • None
    • 0.7.0
    • None

    Description

      IF ELSE statements nested inside IF ELSEstatements can cause problems with short-circuiting. See the following example.

      Stellar>>> IF true THEN IF false THEN true ELSE false ELSE is_alert
      false
      Stellar>>> IF true THEN IF true THEN true ELSE false ELSE is_alert
      ! Invalid parse, found null
      org.apache.metron.stellar.dsl.ParseException: Invalid parse, found null
      at org.apache.metron.stellar.common.StellarCompiler$Expression.apply(StellarCompiler.java:211)
      at org.apache.metron.stellar.common.BaseStellarProcessor.parse(BaseStellarProcessor.java:145)
      at org.apache.metron.stellar.common.shell.DefaultStellarShellExecutor.executeStellar(DefaultStellarShellExecutor.java:401)
      at org.apache.metron.stellar.common.shell.DefaultStellarShellExecutor.execute(DefaultStellarShellExecutor.java:257)
      at org.apache.metron.stellar.common.shell.cli.StellarShell.execute(StellarShell.java:357)
      at org.jboss.aesh.console.AeshProcess.run(AeshProcess.java:53)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      at java.lang.Thread.run(Thread.java:748)

      Attachments

        Issue Links

          Activity

            People

              justinleet Justin Leet
              justinleet Justin Leet
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: