Skip to content

Analyzer

Analyzer is used by QueryAnalyzer to analyze KSQL query statements (and produce an Analysis).

Analyzer

Creating Instance

Analyzer takes the following to be created:

Analyzer is created along with QueryAnalyzer.

Analysing KSQL Query Statement

Analysis analyze(
  Query query,
  Optional<Sink> sink)

analyze creates an Analyzer.Visitor (with the given Query and whether the Sink is present for the persistent flag).

analyze requests the Analyzer.Visitor for the following:

  1. Process the given Query
  2. analyzeNonStdOutSink only if the Sink is defined
  3. Validate

In the end, analyze requests the Analyzer.Visitor for the Analysis.


analyze is used when: