Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SOLR-15904: Move SQL support into new sql module #637

Merged
merged 1 commit into from
Feb 21, 2022

Conversation

risdenk
Copy link
Contributor

@risdenk risdenk commented Feb 15, 2022

Copy link
Contributor

@dsmiley dsmiley left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

gradle/validation/spotless.gradle Show resolved Hide resolved
solr/modules/sql/README.md Outdated Show resolved Hide resolved
solr/core/build.gradle Show resolved Hide resolved
@risdenk risdenk force-pushed the SOLR-15904 branch 5 times, most recently from c77d8c7 to a2d0009 Compare February 15, 2022 16:11
@HoustonPutman
Copy link
Contributor

Is there a page for this SQL functionality that we can add the module information to?

@risdenk
Copy link
Contributor Author

risdenk commented Feb 17, 2022

@HoustonPutman I think you mean https://nightlies.apache.org/solr/draft-guides/solr-reference-guide-antora/solr/10_0/query-guide/sql-query.html potentially? I added a note to enable the plugin to use.

@risdenk
Copy link
Contributor Author

risdenk commented Feb 18, 2022

The biggest outstanding item is fixing the Implicit Plugins to handle this better. Right now it works, but only if SQL handler is enabled. It breaks otherwise. So need to look into that further.

Sadly I haven't made any progress on this yet. I tracked down how these ImplicitPlugins are referenced and created. It just doesn't look like there is a nice way to ignore the failures.

@HoustonPutman
Copy link
Contributor

@risdenk would you mind not force-pushing your changes? Makes it hard to see what has changed since I last viewed. It's easy to squash and merge in the end anyways 🙂

@risdenk
Copy link
Contributor Author

risdenk commented Feb 18, 2022

If you use the PR in github and viewed files it shows exactly what changed. But yea I can try to avoid force pushing. Its clearer to me to make sure the commit is exactly what should be merged.

@risdenk
Copy link
Contributor Author

risdenk commented Feb 19, 2022

Updated based on @dsmiley comment in jira. Use startup=lazy and then fix dependencies for tests.

Copy link
Contributor

@HoustonPutman HoustonPutman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me! Thanks for doing this work 🙂

@@ -62,6 +62,7 @@ dependencies {
testImplementation project(':solr:test-framework')
testImplementation project(':solr:core')
testImplementation project(':solr:solrj')
testRuntimeOnly project(':solr:modules:sql')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whenever the solrj-jdbc solrj-module is split out, this will go in there, correct?

So the dependency tree at that point will look like solr:solrj:jdbc (test) -> solr:modules:sql -> solr:solrj

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dsmiley had a comment about this on the jira as well regarding moving the solrj tests -> sql module. JdbcTest and one of the streamingexpressions jdbc test are what is failing without the testRuntimeOnly project(':solr:modules:sql'). I'm not sure it makes sense to move the solrj jdbc tests to solr:modules:sql since they are really solrj tests. The solrj tests are testing that solrj actually works w/ the SQL module. So I kinda like how the dependencies are defined right now.

Regarding solrj-jdbc module - I would think so unless streaming expressions is somehow still in solrj-core or whatever it will be called.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, definitely don't think they should go in the module, definitely leave them where they are for now. I think this is good to go, and the somewhat-recursive looking dependency (though it's test vs src, so not really recursive) will eventually go away.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I disagree but I'm not going to hold this up. If we're adding a dependency between our modules that can be avoided simply by moving a test -- that's a "smell" to me, and the test should move. I think it's natural that a module might have "solrj level tests" to exercise the backend functional by using higher level APIs... that shouldn't mean (IMO) that SolrJ tests need to depend on nearly everything. At least that's the direction this will go if we follow your logic.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Put differently, if we can make simple moves to reduce intermodule dependencies, even just tests, that's a good thing.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I understand your point David, and I think if this was a long term thing I would definitely agree. However I don't particularly mind which solution we go with in this case, since it's really a temporary band-aid until we have the solrj sub-modules, which shouldn't be too far off

@risdenk risdenk changed the title SOLR-15904: Create sql module SOLR-15904: Move SQL support into new sql module Feb 21, 2022
@risdenk risdenk merged commit d3cc94f into apache:main Feb 21, 2022
@risdenk risdenk deleted the SOLR-15904 branch February 21, 2022 17:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants