[VOTE] Release apache-calcite-avatica-go-5.0.0 (release candidate 0)

2020-06-22 Thread Francis Chuang

Hi all,

I have created a release for Apache Calcite Avatica Go 5.0.0, release 
candidate 0.


Thanks to everyone who has contributed to this release. The release 
notes are available here:

https://github.com/apache/calcite-avatica-go/blob/0e3f5df582a09ac90869611b2d0a64b9f9b566e2/site/_docs/go_history.md

The commit to be voted on:
https://gitbox.apache.org/repos/asf?p=calcite-avatica-go.git;a=commit;h=0e3f5df582a09ac90869611b2d0a64b9f9b566e2

The hash is 0e3f5df582a09ac90869611b2d0a64b9f9b566e2

The artifacts to be voted on are located here:
https://dist.apache.org/repos/dist/dev/calcite/apache-calcite-avatica-go-5.0.0-rc0/

The hashes of the artifacts are as follows:
src.tar.gz C49DB10E 5CC08815 2EEFFC83 7DD339DF 3327125E DCBA5DA3 
9C9E74E1 F277D554 34DBE407 5436849A A4124661 4527A769 80EA7334 8ABDB2FE 
56AA5B20 4FDFA43D


Release artifacts are signed with the following key:
https://people.apache.org/keys/committer/francischuang.asc

Instructions for running the test suite is located here:
https://github.com/apache/calcite-avatica-go/blob/0e3f5df582a09ac90869611b2d0a64b9f9b566e2/site/develop/avatica-go.md#testing

Please vote on releasing this package as Apache Calcite Avatica Go 5.0.0.

To run the tests without a Go environment, install docker and 
docker-compose. Then, in the root of the release's directory, run: 
docker-compose run test


When the test suite completes, run "docker-compose down" to remove and 
shutdown all the containers.


The vote is open for the next 72 hours and passes if a majority of at 
least three +1 PMC votes are cast.


[ ] +1 Release this package as Apache Calcite Avatica Go 5.0.0
[ ]  0 I don't feel strongly about it, but I'm okay with the release
[ ] -1 Do not release this package because...


Here is my vote:

+1 (binding)

Francis


Calcite-Master - Build # 1804 - Failure

2020-06-22 Thread Apache Jenkins Server
The Apache Jenkins build system has built Calcite-Master (build #1804)

Status: Failure

Check console output at https://builds.apache.org/job/Calcite-Master/1804/ to 
view the results.

Re: [ANNOUNCE] Apache Calcite Avatica 1.17.0 released

2020-06-22 Thread Danny Chan
Thanks for the work, Francis~

Francis Chuang 于2020年6月23日 周二上午8:10写道:

> The Apache Calcite team is pleased to announce the release of Apache
> Calcite Avatica 1.17.0.
>
> Avatica is a framework for building database drivers. Avatica defines a
> wire API and serialization mechanism for clients to communicate with a
> server as a proxy to a database. The reference Avatica client and server
> are implemented in Java and communicate over HTTP. Avatica is a
> sub-project of Apache Calcite
>
> Apache Calcite Avatica 1.17.0 is a small routine release that includes a
> few dependency updates and bug fixes. Of particular note is a fix to
> resolve a multilingual decoding issue that parses Chinese characters as
> gibberish. This release has also been tested with JDK 14 and Guava 29.
> For a full list of changes, please see the release notes:
>
>https://calcite.apache.org/avatica/docs/history.html#v1-17-0
>
> The release is available here:
>
>https://calcite.apache.org/avatica/downloads/avatica.html
>
> We welcome your help and feedback. For more information on how to report
> problems and get involved, visit the project website at:
>
> https://calcite.apache.org/avatica/
>
> or the Apache Calcite project website:
>
> https://calcite.apache.org/
>
> Thanks to everyone involved!
>
> Francis Chuang, on behalf of the Apache Calcite team.
>


[ANNOUNCE] Apache Calcite Avatica 1.17.0 released

2020-06-22 Thread Francis Chuang
The Apache Calcite team is pleased to announce the release of Apache 
Calcite Avatica 1.17.0.


Avatica is a framework for building database drivers. Avatica defines a 
wire API and serialization mechanism for clients to communicate with a 
server as a proxy to a database. The reference Avatica client and server
are implemented in Java and communicate over HTTP. Avatica is a 
sub-project of Apache Calcite


Apache Calcite Avatica 1.17.0 is a small routine release that includes a 
few dependency updates and bug fixes. Of particular note is a fix to 
resolve a multilingual decoding issue that parses Chinese characters as 
gibberish. This release has also been tested with JDK 14 and Guava 29. 
For a full list of changes, please see the release notes:


  https://calcite.apache.org/avatica/docs/history.html#v1-17-0

The release is available here:

  https://calcite.apache.org/avatica/downloads/avatica.html

We welcome your help and feedback. For more information on how to report
problems and get involved, visit the project website at:

   https://calcite.apache.org/avatica/

or the Apache Calcite project website:

   https://calcite.apache.org/

Thanks to everyone involved!

Francis Chuang, on behalf of the Apache Calcite team.


[jira] [Created] (CALCITE-4083) RelTraitSet failed to canonize traits

2020-06-22 Thread Haisheng Yuan (Jira)
Haisheng Yuan created CALCITE-4083:
--

 Summary: RelTraitSet failed to canonize traits
 Key: CALCITE-4083
 URL: https://issues.apache.org/jira/browse/CALCITE-4083
 Project: Calcite
  Issue Type: Bug
  Components: core
Reporter: Haisheng Yuan


RelTraitSet#plus uses FlatLists and ImmutableList. They have different hash 
algorithms, and they are all different classes from RelTraitSet. The 
RelTraitSet equality requires the other object must be RelTraitSet too, and the 
HashMap#get(key) uses key.equals() to check equality, instead of the other way. 
In case we pass RelTraitSet as the search key to cache, but the cached entry 
has key with FlatLists or ImmutableList, we may fail to find the cached 
RelTraitSet. Due to this, using == to check traitSet equality may fail, even 
they have same traits.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (CALCITE-4082) Intermittent failures of RelMetadataTest#testPullUpPredicatesFromUnion2 in Windows

2020-06-22 Thread Stamatis Zampetakis (Jira)
Stamatis Zampetakis created CALCITE-4082:


 Summary: Intermittent failures of 
RelMetadataTest#testPullUpPredicatesFromUnion2 in Windows
 Key: CALCITE-4082
 URL: https://issues.apache.org/jira/browse/CALCITE-4082
 Project: Calcite
  Issue Type: Bug
  Components: core
Reporter: Stamatis Zampetakis


The test fails from time to time in Windows since the order of pulled up 
predicates appears to be different from one execution to the other. 

Locally (on Ubuntu), I cannot reproduce but I've seen it a few times in the 
[CI|https://github.com/apache/calcite/runs/789868941?check_suite_focus=true#step:4:495].

{noformat}
FAILURE   0.0sec, org.apache.calcite.test.RelMetadataTest > 
testPullUpPredicatesFromUnion2()
java.lang.AssertionError: 
Expected: "[=($0, 1), OR(AND(=($1, 2), =($2, 3)), =($1, 4))]"
 but: was "[=($0, 1), OR(AND(=($2, 3), =($1, 2)), =($1, 4))]"
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:18)
at org.hamcrest.MatcherAssert.assertThat(MatcherAssert.java:6)
at 
org.apache.calcite.test.RelMetadataTest.testPullUpPredicatesFromUnion2(RelMetadataTest.java:2039)
{noformat}




--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (CALCITE-4081) Round-tripping a DECIMAL literal through Planner -> RelToSqlConverter -> Planner throws validation error

2020-06-22 Thread Steven Talbot (Jira)
Steven Talbot created CALCITE-4081:
--

 Summary: Round-tripping a DECIMAL literal through Planner -> 
RelToSqlConverter -> Planner throws validation error
 Key: CALCITE-4081
 URL: https://issues.apache.org/jira/browse/CALCITE-4081
 Project: Calcite
  Issue Type: Bug
Reporter: Steven Talbot


Take the following SQL:
SELECT CAST('.11' AS DECIMAL(38,6)) AS "num"
And, in the default Calcite SQL dialect with all defaults, send it through 
Planner parse -> valiate -> rel to get a RelNode. The RelNode will have a 
Project with the "111.1" literal in there as a RexLiteral with 
Decimal type. 

 

The use RelToSqlConverter to convert that RelNode back to SQL. The SQL now 
looks like 
SELECT .11 AS "num"
 

If you attempt to parse and validate that SQL, you get "Numeric literal 
'.11' out of range" throw by 
SqlValidatorImpl.validateLiteral()



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


Calcite-Master - Build # 1802 - Still Failing

2020-06-22 Thread Apache Jenkins Server
The Apache Jenkins build system has built Calcite-Master (build #1802)

Status: Still Failing

Check console output at https://builds.apache.org/job/Calcite-Master/1802/ to 
view the results.

[jira] [Created] (CALCITE-4080) Exception occurs when parsing quoted aliases for select columns

2020-06-22 Thread Dan Cojocaru (Jira)
Dan Cojocaru created CALCITE-4080:
-

 Summary: Exception occurs when parsing quoted aliases for select 
columns
 Key: CALCITE-4080
 URL: https://issues.apache.org/jira/browse/CALCITE-4080
 Project: Calcite
  Issue Type: Bug
  Components: core
Affects Versions: 1.23.0
Reporter: Dan Cojocaru


Exception occurs while parsing query with quoted alias for select columns. 
{code:java}
final FrameworkConfig config = Frameworks.newConfigBuilder() 
.parserConfig(SqlParser.configBuilder().setLex(Lex.MYSQL) 
.setConformance(SqlConformanceEnum.MYSQL_5).build()) 
.programs(Programs.ofRules(Programs.RULE_SET)) .build(); 

Planner p = Frameworks.getPlanner(config); 

SqlNode n = p.parse("SELECT 1 AS 'some alias' from dual");

{code}
The following exception is thrown: 
{code:java}
org.apache.calcite.sql.parser.SqlParseException: Encountered "\'some alias\'" 
at line 1, column 13.
Was expecting one of:
 ...
 ...
 ...
 ...
 ...{code}
If query is changed into :  
{code:java}
"SELECT 1 AS some_alias from dual"
{code}
The query is parsed correctly.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (CALCITE-4079) Remove the deprecated code from SqlDialect

2020-06-22 Thread TANG Wen-hui (Jira)
TANG Wen-hui created CALCITE-4079:
-

 Summary: Remove the deprecated code from SqlDialect
 Key: CALCITE-4079
 URL: https://issues.apache.org/jira/browse/CALCITE-4079
 Project: Calcite
  Issue Type: Improvement
  Components: core
Affects Versions: 1.23.0
Reporter: TANG Wen-hui


{code:java}
/** @deprecated Use {@link AnsiSqlDialect#DEFAULT} instead. */
@Deprecated // to be removed before 2.0
public static final SqlDialect DUMMY =
AnsiSqlDialect.DEFAULT;

/** @deprecated Use {@link CalciteSqlDialect#DEFAULT} instead. */
@Deprecated // to be removed before 2.0
public static final SqlDialect CALCITE =
CalciteSqlDialect.DEFAULT;{code}
SqlDialect#DUMMY and SqlDialect#CALCITE are marked deprecated and have not be 
used in any places.
It would be better to remove them to avoid class initialization deadlock.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[DISCUSS] Towards Avatica-Go 5.0.0

2020-06-22 Thread Francis Chuang
Now that Avatica 1.17.0 is almost finalized, I plan to release 
Avatica-Go 5.0.0 soon. The last release was more than a year ago, so I 
think it's a good time to get the next release out.


This should be a fairly straight-forward released. There is a breaking 
change in this version due to moving the query-based connection 
key-value pairs from the string DSN into a proper map in the new 
Connector struct. Other than that, there were some minor bug fixes and 
routine dependency updates.


I'll make rc0 available for voting very soon. If you have any questions 
or comments, please let me know in this thread :)


Francis


Calcite-Master - Build # 1801 - Still Failing

2020-06-22 Thread Apache Jenkins Server
The Apache Jenkins build system has built Calcite-Master (build #1801)

Status: Still Failing

Check console output at https://builds.apache.org/job/Calcite-Master/1801/ to 
view the results.

[jira] [Created] (CALCITE-4078) Release avatica-go 5.0.0

2020-06-22 Thread Francis Chuang (Jira)
Francis Chuang created CALCITE-4078:
---

 Summary: Release avatica-go 5.0.0
 Key: CALCITE-4078
 URL: https://issues.apache.org/jira/browse/CALCITE-4078
 Project: Calcite
  Issue Type: Task
Reporter: Francis Chuang
Assignee: Francis Chuang
 Fix For: avatica-go-5.0.0






--
This message was sent by Atlassian Jira
(v8.3.4#803005)