Re:SQL in CockroachDB: Mapping Table Data to Key-Value Stora...
by elvinyung on Sunday July 09, 2017 @09:58AM
(#14729759)
There's overhead in the flexibility, but it seems that you'll have to do the same kind of tuning all over again if you build your own query engine from scratch. And frankly it seems (at least at a high level) that Cockroach is heading towards building the exact same kind of dataflow engine anyways[1].
Spark has some support for SQL DML, and to me it actually mostly seems like a concern for the underlying KV layer to provide ACID transactions, and expose them to Spark through the Data Sources API.
[1] https://www.cockroachlabs.com/blog/local-and-distributed-pro...
Also, last I checked Spark had very limited support for mutating data in SQL; it was designed for queries. Cockroach has to do both.