You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Daniel John Debrunner (JIRA)" <de...@db.apache.org> on 2006/01/04 18:28:01 UTC

[jira] Commented: (DERBY-791) Expose api for printing Abstract Syntax Trees in production (non-debug) servers

    [ http://issues.apache.org/jira/browse/DERBY-791?page=comments#action_12361765 ] 

Daniel John Debrunner commented on DERBY-791:
---------------------------------------------

I was thinking about something similar over the holiday period. I don't think the current mechanism should be used, but instead the tree could be represented as an XML document. It would be great to tie this into the runtime statistics output, so that there was a common XML format for displaying query information.
It would be good to also make this optional in a production server, rather than increasing the footprint for every deployment. If the node factory was not removed (see DERBY-673) then a debugging node factory option could return nodes that provide the tree printing. This debugging code could be in a separate jar file to the base engine, thus only incurring a footprint cost when runtime debugging is required.

> Expose api for printing Abstract Syntax Trees in production (non-debug) servers
> -------------------------------------------------------------------------------
>
>          Key: DERBY-791
>          URL: http://issues.apache.org/jira/browse/DERBY-791
>      Project: Derby
>         Type: Improvement
>     Reporter: Rick Hillegas

>
> Currently you can print Abstract Syntax Trees to derby.log by setting the DumpParseTree tracepoint at server startup. E.g.:
> java -cp $CLASSPATH -Dderby.debug.true=DumpParseTree -Dderby.stream.error.logSeverityLevel=0 org.apache.derby.tools.ij  z.sql
> This can be a useful debugging tool. However, it only works on debug servers built with the following flags:
> sanity=true
> debug=true
> We should provide some mechanism for printing these trees in production (non-debug) servers.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira