You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@solr.apache.org by "Joel Bernstein (Jira)" <ji...@apache.org> on 2022/06/03 22:15:00 UTC

[jira] [Comment Edited] (SOLR-16238) Code level documentation for Solr SQL

    [ https://issues.apache.org/jira/browse/SOLR-16238?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17547339#comment-17547339 ] 

Joel Bernstein edited comment on SOLR-16238 at 6/3/22 10:14 PM:
----------------------------------------------------------------

There are some serious mysteries that need to be unraveled in order to document this code. One of big mysteries is how rules actually fire. 

Then solrImplementer is instantiated and empty here:

https://github.com/apache/solr/blob/03efd00a4fe2b5f946cf539c3ef831ff55d4f07b/solr/modules/sql/src/java/org/apache/solr/handler/sql/SolrToEnumerableConverter.java#L57

By the time it reaches this line it's populated by rules that have fired:

https://github.com/apache/solr/blob/03efd00a4fe2b5f946cf539c3ef831ff55d4f07b/solr/modules/sql/src/java/org/apache/solr/handler/sql/SolrToEnumerableConverter.java#L70


So somewhere between line 57 and 70 the rules have fired. The most likely place where the rules fire is:

https://github.com/apache/solr/blob/03efd00a4fe2b5f946cf539c3ef831ff55d4f07b/solr/modules/sql/src/java/org/apache/solr/handler/sql/SolrToEnumerableConverter.java#L58

Some debugging in the code will confirm this.













was (Author: joel.bernstein):
There are some serious mysteries need to be unraveled in order to document this code. One of big mysteries is how rules actually fire. 

Then solrImplementer is instantiated and empty here:

https://github.com/apache/solr/blob/03efd00a4fe2b5f946cf539c3ef831ff55d4f07b/solr/modules/sql/src/java/org/apache/solr/handler/sql/SolrToEnumerableConverter.java#L57

By the time it reaches this line it's populated by rules that have fired:

https://github.com/apache/solr/blob/03efd00a4fe2b5f946cf539c3ef831ff55d4f07b/solr/modules/sql/src/java/org/apache/solr/handler/sql/SolrToEnumerableConverter.java#L70


So somewhere between line 57 and 70 the rules have fired. The most likely place where the rules fire is:

https://github.com/apache/solr/blob/03efd00a4fe2b5f946cf539c3ef831ff55d4f07b/solr/modules/sql/src/java/org/apache/solr/handler/sql/SolrToEnumerableConverter.java#L58

Some debugging in the code will confirm this.












> Code level documentation for Solr SQL
> -------------------------------------
>
>                 Key: SOLR-16238
>                 URL: https://issues.apache.org/jira/browse/SOLR-16238
>             Project: Solr
>          Issue Type: Task
>      Security Level: Public(Default Security Level. Issues are Public) 
>          Components: Parallel SQL
>            Reporter: Joel Bernstein
>            Assignee: Joel Bernstein
>            Priority: Major
>
> The Solr SQL module is an Apache Calcite adaptor. I find the Apache Calcite framework quite confusing. So, for my own knowledge and for future devs who want to contribute to Solr SQL, I'd like to take the time to document the code thoroughly.



--
This message was sent by Atlassian Jira
(v8.20.7#820007)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@solr.apache.org
For additional commands, e-mail: issues-help@solr.apache.org