You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@calcite.apache.org by jh...@apache.org on 2016/03/22 05:45:10 UTC

[2/3] calcite git commit: Add news item for release 1.7.0 and Cassandra adapter

Add news item for release 1.7.0 and Cassandra adapter

Also:
* Fix up release notes;
* Make documentation links relative to site base URL;
* Link to Cassandra from Adapters page;
* Trim trailing spaces.


Project: http://git-wip-us.apache.org/repos/asf/calcite/repo
Commit: http://git-wip-us.apache.org/repos/asf/calcite/commit/83266054
Tree: http://git-wip-us.apache.org/repos/asf/calcite/tree/83266054
Diff: http://git-wip-us.apache.org/repos/asf/calcite/diff/83266054

Branch: refs/heads/master
Commit: 83266054098220d33be02be38a8a230ca6d6fd38
Parents: 00e755d
Author: Julian Hyde <jh...@apache.org>
Authored: Wed Mar 16 14:53:42 2016 -0700
Committer: Julian Hyde <jh...@apache.org>
Committed: Mon Mar 21 20:19:36 2016 -0700

----------------------------------------------------------------------
 site/_docs/adapter.md                       |  2 +-
 site/_docs/cassandra.md                     | 39 +++++++++------
 site/_docs/history.md                       | 10 ++--
 site/_docs/howto.md                         |  2 +-
 site/_docs/stream.md                        |  6 +--
 site/_posts/2016-03-22-cassandra-adapter.md | 42 ++++++++++++++++
 site/_posts/2016-03-22-release-1.7.0.md     | 64 ++++++++++++++++++++++++
 7 files changed, 141 insertions(+), 24 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/calcite/blob/83266054/site/_docs/adapter.md
----------------------------------------------------------------------
diff --git a/site/_docs/adapter.md b/site/_docs/adapter.md
index 13320b9..93ea1c9 100644
--- a/site/_docs/adapter.md
+++ b/site/_docs/adapter.md
@@ -27,7 +27,7 @@ limitations under the License.
 A schema adapter allows Calcite to read particular kind of data,
 presenting the data as tables within a schema.
 
-* Cassandra adapter (<a href="{{ site.apiRoot }}/org/apache/calcite/adapter/cassandra/package-summary.html">calcite-cassandra</a>)
+* [Cassandra adapter](cassandra.html) (<a href="{{ site.apiRoot }}/org/apache/calcite/adapter/cassandra/package-summary.html">calcite-cassandra</a>)
 * CSV adapter (<a href="{{ site.apiRoot }}/org/apache/calcite/adapter/csv/package-summary.html">example/csv</a>)
 * JDBC adapter (part of <a href="{{ site.apiRoot }}/org/apache/calcite/adapter/jdbc/package-summary.html">calcite-core</a>)
 * MongoDB adapter (<a href="{{ site.apiRoot }}/org/apache/calcite/adapter/mongodb/package-summary.html">calcite-mongodb</a>)

http://git-wip-us.apache.org/repos/asf/calcite/blob/83266054/site/_docs/cassandra.md
----------------------------------------------------------------------
diff --git a/site/_docs/cassandra.md b/site/_docs/cassandra.md
index dcff107..58a139c 100644
--- a/site/_docs/cassandra.md
+++ b/site/_docs/cassandra.md
@@ -23,13 +23,16 @@ limitations under the License.
 -->
 
 For instructions on downloading and building Calcite, start with the
-[tutorial](/docs/tutorial.html). Once you've managed to compile the
-project, you can return here to start querying Cassandra with Calcite.
-First, we need a [model definition](/docs/model.html). The model gives
-Calcite the necessary parameters to create an instance of the Cassandra
-adapter. Note that while models can contain definitions of
-[materializations](/docs/model.html#materialization), the adapter will
-attempt to automatically populate any materialized views
+[tutorial]({{ site.baseurl }}/docs/tutorial.html).
+
+Once you've managed to compile the project, you can return here to
+start querying Cassandra with Calcite.  First, we need a
+[model definition]({{ site.baseurl }}/docs/model.html).
+The model gives Calcite the necessary parameters to create an instance
+of the Cassandra adapter. Note that while models can contain
+definitions of
+[materializations]({{ site.baseurl }}/docs/model.html#materialization),
+the adapter will attempt to automatically populate any materialized views
 [defined in Cassandra](http://www.datastax.com/dev/blog/new-in-cassandra-3-0-materialized-views).
 
 A basic example of a model file is given below:
@@ -52,7 +55,9 @@ A basic example of a model file is given below:
 }
 {% endhighlight %}
 
-Assuming this file is stored as `model.json`, you can connect to Cassandra via [`sqlline`](https://github.com/julianhyde/sqlline) as follows:
+Assuming this file is stored as `model.json`, you can connect to
+Cassandra via [`sqlline`](https://github.com/julianhyde/sqlline) as
+follows:
 
 {% highlight bash %}
 $ ./sqlline
@@ -74,12 +79,15 @@ We can issue a simple query to fetch the most recent tweet ID of the
 user by writing standard SQL:
 
 {% highlight sql %}
-sqlline> SELECT "tweet_id" FROM "timeline" WHERE "username"='JmuhsAaMdw' ORDER BY "time" DESC LIMIT 1;
-+----------+
-| tweet_id |
-+----------+
+sqlline> SELECT "tweet_id"
+         FROM "timeline"
+         WHERE "username" = 'JmuhsAaMdw'
+         ORDER BY "time" DESC LIMIT 1;
++--------------------------------------+
+| tweet_id                             |
++--------------------------------------+
 | f3d3d4dc-d05b-11e5-b58b-90e2ba530b12 |
-+----------+
++--------------------------------------+
 {% endhighlight %}
 
 While executing this query, the Cassandra adapter is able to recognize
@@ -90,7 +98,10 @@ Cassandra as well.
 The final CQL query given to Cassandra is below:
 
 {% highlight sql %}
-SELECT username, time, tweet_id FROM "timeline" WHERE username = 'JmuhsAaMdw' ORDER BY time DESC ALLOW FILTERING;
+SELECT username, time, tweet_id
+FROM "timeline"
+WHERE username = 'JmuhsAaMdw'
+ORDER BY time DESC ALLOW FILTERING;
 {% endhighlight %}
 
 There is still significant work to do in improving the flexibility and

http://git-wip-us.apache.org/repos/asf/calcite/blob/83266054/site/_docs/history.md
----------------------------------------------------------------------
diff --git a/site/_docs/history.md b/site/_docs/history.md
index 544d465..fcd20c2 100644
--- a/site/_docs/history.md
+++ b/site/_docs/history.md
@@ -32,8 +32,8 @@ Downloads are available on the
 {: #v1-7-0}
 
 This is the first Apache Calcite release since
-[Avatica became an independent project)({{ site.baseurl }}/avatica/news/2016/03/03/separate-project/).
-Calcite now depends on [Avatica]{{ site.baseurl }}/avatica/) in the
+[Avatica became an independent project]({{ site.baseurl }}/avatica/news/2016/03/03/separate-project/).
+Calcite now depends on [Avatica]({{ site.baseurl }}/avatica/) in the
 same way as it does other libraries, via a Maven dependency. To see
 Avatica-related changes, see the
 [release notes for Avatica 1.7.1]({{ site.baseurl }}/avatica/docs/history.html#v1-7-1).
@@ -42,13 +42,13 @@ We have [added](https://issues.apache.org/jira/browse/CALCITE-1080)
 an [adapter]({{ site.baseurl }}/docs/adapter.html) for
 [Apache Cassandra](http://cassandra.apache.org/).
 You can map a Cassandra keyspace into Calcite as a schema, Cassandra
-data sets as tables, and execute SQL queries on them, which Calcite
+CQL tables as tables, and execute SQL queries on them, which Calcite
 converts into [CQL](https://cassandra.apache.org/doc/cql/CQL.html).
 Cassandra can define and maintain materialized views but the adapter
 goes further: it can transparently rewrite a query to use a
-materialized view even if view is not mentioned in the query.
+materialized view even if the view is not mentioned in the query.
 
-We have started work on an
+This release adds an
 [Oracle-compatibility mode](https://issues.apache.org/jira/browse/CALCITE-1066).
 If you add `fun=oracle` to your JDBC connect string, you get all of
 the standard operators and functions plus Oracle-specific functions

http://git-wip-us.apache.org/repos/asf/calcite/blob/83266054/site/_docs/howto.md
----------------------------------------------------------------------
diff --git a/site/_docs/howto.md b/site/_docs/howto.md
index 3ff83f7..531fca2 100644
--- a/site/_docs/howto.md
+++ b/site/_docs/howto.md
@@ -209,7 +209,7 @@ log4j.logger.org.apache.calcite.plan.hep.HepPlanner=TRACE
 
 ## CSV adapter
 
-See the [tutorial](/docs/tutorial.html).
+See the [tutorial]({{ site.baseurl }}/docs/tutorial.html).
 
 ## MongoDB adapter
 

http://git-wip-us.apache.org/repos/asf/calcite/blob/83266054/site/_docs/stream.md
----------------------------------------------------------------------
diff --git a/site/_docs/stream.md b/site/_docs/stream.md
index f66fbce..63bdfcb 100644
--- a/site/_docs/stream.md
+++ b/site/_docs/stream.md
@@ -867,9 +867,9 @@ SELECT STREAM * FROM Orders WHERE units > 1000;
 
 These look similar, and in both cases the next step(s) in the pipeline
 can read from `LargeOrders` without worrying how it was populated.
-There is a difference in efficiency: the `INSERT` statement does the 
+There is a difference in efficiency: the `INSERT` statement does the
 same work no matter how many consumers there are; the view does work
-proportional to the number of consumers, and in particular, does no 
+proportional to the number of consumers, and in particular, does no
 work if there are no consumers.
 
 Other forms of DML make sense for streams. For example, the following
@@ -971,7 +971,7 @@ negative cases) and the TCK tests it.
 * Fix the `UPSERT` example to remove records for products that have not
   occurred in the last hour.
 * DML that outputs to multiple streams; perhaps an extension to the standard
-  `REPLACE` statement. 
+  `REPLACE` statement.
 
 # Functions
 

http://git-wip-us.apache.org/repos/asf/calcite/blob/83266054/site/_posts/2016-03-22-cassandra-adapter.md
----------------------------------------------------------------------
diff --git a/site/_posts/2016-03-22-cassandra-adapter.md b/site/_posts/2016-03-22-cassandra-adapter.md
new file mode 100644
index 0000000..f33c976
--- /dev/null
+++ b/site/_posts/2016-03-22-cassandra-adapter.md
@@ -0,0 +1,42 @@
+---
+layout: news_item
+date: "2016-03-22 13:00:00 +0000"
+author: jhyde
+categories: ["new features"]
+---
+<!--
+{% comment %}
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to you under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+{% endcomment %}
+-->
+
+A new Apache Calcite adapter allows you to access
+[Apache Cassandra](http://cassandra.apache.org/) via industry-standard SQL.
+
+You can map a Cassandra keyspace into Calcite as a schema, Cassandra
+CQL tables as tables, and execute SQL queries on them, which Calcite
+converts into [CQL](https://cassandra.apache.org/doc/cql/CQL.html).
+Cassandra can define and maintain materialized views but the adapter
+goes further: it can transparently rewrite a query to use a
+materialized view even if the view is not mentioned in the query.
+
+Read more about the adapter [here]({{ site.baseurl }}/docs/cassandra.html).
+
+The Cassandra adapter is available as part of
+[Apache Calcite version 1.7.0]({{ site.baseurl }}/docs/history.html#v1-7-0),
+which has just been released. Calcite also has
+[adapters]({{ site.baseurl }}/docs/adapter.html)
+for CSV and JSON files, and JDBC data source, MongoDB, Spark and Splunk.

http://git-wip-us.apache.org/repos/asf/calcite/blob/83266054/site/_posts/2016-03-22-release-1.7.0.md
----------------------------------------------------------------------
diff --git a/site/_posts/2016-03-22-release-1.7.0.md b/site/_posts/2016-03-22-release-1.7.0.md
new file mode 100644
index 0000000..81fa624
--- /dev/null
+++ b/site/_posts/2016-03-22-release-1.7.0.md
@@ -0,0 +1,64 @@
+---
+layout: news_item
+date: "2016-03-22 12:00:00 +0000"
+author: jhyde
+version: 1.7.0
+categories: [release]
+tag: v1-7-0
+sha: 8eebfc6
+---
+<!--
+{% comment %}
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to you under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+{% endcomment %}
+-->
+
+Apache Calcite 1.7.0 is the first release since
+[Avatica became an independent project]({{ site.baseurl }}/avatica/news/2016/03/03/separate-project/).
+Calcite now depends on [Avatica]({{ site.baseurl }}/avatica/) in the
+same way as it does other libraries, via a Maven dependency. To see
+Avatica-related changes, see the
+[release notes for Avatica 1.7.1]({{ site.baseurl }}/avatica/docs/history.html#v1-7-1).
+
+We have [added](https://issues.apache.org/jira/browse/CALCITE-1080)
+an [adapter]({{ site.baseurl }}/docs/cassandra.html) for
+[Apache Cassandra](http://cassandra.apache.org/).
+You can map a Cassandra keyspace into Calcite as a schema, Cassandra
+CQL tables as tables, and execute SQL queries on them, which Calcite
+converts into [CQL](https://cassandra.apache.org/doc/cql/CQL.html).
+Cassandra can define and maintain materialized views but the adapter
+goes further: it can transparently rewrite a query to use a
+materialized view even if the view is not mentioned in the query.
+
+This release adds an
+[Oracle-compatibility mode](https://issues.apache.org/jira/browse/CALCITE-1066).
+If you add `fun=oracle` to your JDBC connect string, you get all of
+the standard operators and functions plus Oracle-specific functions
+`DECODE`, `NVL`, `LTRIM`, `RTRIM`, `GREATEST` and `LEAST`. We look
+forward to adding more functions, and compatibility modes for other
+databases, in future releases.
+
+We've replaced our use of JUL (`java.util.logging`)
+with [SLF4J](http://slf4j.org/). SLF4J provides an API which Calcite can use
+independent of the logging implementation. This ultimately provides additional
+flexibility to users, allowing them to configure Calcite's logging within their
+own chosen logging framework. This work was done in
+[[CALCITE-669](https://issues.apache.org/jira/browse/CALCITE-669)].
+
+For users experienced with configuring JUL in Calcite previously, there are some
+differences as some the JUL logging levels do not exist in SLF4J: `FINE`,
+`FINER`, and `FINEST`, specifically. To deal with this, `FINE` was mapped
+to SLF4J's `DEBUG` level, while `FINER` and `FINEST` were mapped to SLF4J's `TRACE`.