Julian Hyde commented on CALCITE-1383:

The strategy is to use freemarker templates to extend the parser. That means 
that you need to insert tokens into the base parser at points where the derived 
parser needs to be different. The strategy isn't ideal, because you sometimes 
have to contribute patches back to Calcite to create those extension points, 
but I think it works OK.

> Allow extensions to existing Calcite parser rules
> -------------------------------------------------
>                 Key: CALCITE-1383
>                 URL: https://issues.apache.org/jira/browse/CALCITE-1383
>             Project: Calcite
>          Issue Type: Improvement
>            Reporter: James Taylor
>            Assignee: Julian Hyde
> In Phoenix, we'd like to add some Phoenix-specific commands in support of our 
> UDF implementation. For example, we'd like to add commands like to manage the 
> jars containing the implementation of the UDFs:
> Without copy/pasting the entire parser grammar for the command (see comment 
> here[1]), it seems there's no easy way to do it. Perhaps we're missing 
> something and there's already an easy way?
> [1] 
> https://issues.apache.org/jira/browse/PHOENIX-3242?focusedCommentId=15512529&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-15512529

This message was sent by Atlassian JIRA

Reply via email to