Please take a look at 716 <https://github.com/apache/calcite/pull/716>. This is an example for ES adapters (only elastic2 at this point).
For now I have implemented just basic queries, while the plan is to execute existing adapter IT tests as part of unit tests phase. To achieve that, calcite-test-dataset artifacts need to be available in maven central. Also, for unit tests, I would suggest to add a smaller set (eg ~10-50 records called zips-mini.json) compared to existing 30k records in zips.json ? Let me know what you think. On Thu, May 31, 2018 at 10:27 AM, Andrei Sereda <[email protected]> wrote: > Not right now. I'll be adding similar test for ES adapter > > On Thu, May 31, 2018, 10:22 Michael Mior <[email protected]> wrote: > >> Unless you have anything else you want to add immediately, I think it's >> good to merge as-is. We can always add additional data and test cases in >> the future. >> >> -- >> Michael Mior >> [email protected] >> >> >> Le jeu. 31 mai 2018 à 00:53, Andrei Sereda <[email protected]> a écrit : >> >> > Pls take a look at PR 715 <https://github.com/apache/calcite/pull/715> >> and >> > let me know what you think. >> > >> > I'm not sure if one should reuse existing dataset >> > <https://github.com/vlsi/calcite-test-dataset> (zips.json ~ 3MB), >> smaller >> > one or manually populate the database. If former, .json should be >> present >> > somewhere in classpath most likely distributed with calcite source. >> > >> > Feedback is welcome. >> > >> > On Tue, May 29, 2018 at 8:25 AM, Michael Mior <[email protected]> wrote: >> > >> > > I'd definitely be open to this if we can get something stable working. >> > > Anything which gets better regular test coverage for the adapters is >> > great >> > > in my books. >> > > >> > > -- >> > > Michael Mior >> > > [email protected] >> > > >> > > >> > > >> > > Le lun. 28 mai 2018 à 23:47, Andrei Sereda <[email protected]> a >> écrit : >> > > >> > > > Hello, >> > > > >> > > > Current IT tests require manual startup and seeding of data-sources >> > > (Mongo, >> > > > ES, Geode etc.) from separate git project (see calcite-test-dataset >> > > > <https://github.com/vlsi/calcite-test-dataset> ). While useful they >> > > force >> > > > developer to bootstrap additional environment on his own and don't >> work >> > > by >> > > > default (unless properly initialized). >> > > > >> > > > Would you consider using "fake" (in memory) data-sources for unit >> tests >> > > > like: >> > > > - Fongo <https://github.com/fakemongo/fongo> for Mongo >> > > > - TestNode >> > > > < >> > > > https://github.com/dremio/dremio-oss/blob/master/ >> > > plugins/elasticsearch/src/test/java/org/elasticsearch/ >> > > node/ElasticTestNode.java >> > > > > >> > > > for ElasticSearch >> > > > >> > > > I'm not proposing to stop using IT but rather having a better >> coverage >> > > for >> > > > unit tests (with fakes) >> > > > >> > > > Interesting to hear your opinion. >> > > > >> > > > Regards, >> > > > Andrei. >> > > > >> > > >> > >> >
