git.net

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Elasticsearch Adapter. Removal of Mapping Types (by vendor). Index == Table


Hello,

Elastic announced
<https://www.elastic.co/guide/en/elasticsearch/reference/master/removal-of-types.html>
that they will be deprecating mapping types in ES6 and indexes will be
single-typed only.

Historical analogy <https://www.elastic.co/blog/index-vs-type> between
RDBMS and elastic was that index is equivalent to a database and type
corresponds to table in that database. In a couple of releases (ES6-8) this
shall not longer be true.

Recent SQL addition
<https://www.elastic.co/blog/elasticsearch-6-3-0-released> to elastic confirms
this trend
<https://www.elastic.co/guide/en/elasticsearch/reference/current/_mapping_concepts_across_sql_and_elasticsearch.html>.
Index is equivalent to a table and there are no more ES types.

I would like to propose to include this logic in Calcite ES adapter. IE,
expose each ES single-typed index as a separate table inside calcite
schema. This is in contrast to  current integration where schema can only
have a single index. Current approach forces you to create multiple schemas
to query single-typed indexes (on the same ES cluster).

Legacy compatibility can always be controlled with configuration parameters.

Do you agree with such changes ? If yes, would you consider a PR ?

Regards,
Andrei.