Commit Graph

139 Commits

Author SHA1 Message Date
Alexander Kuzmenkov
3da533766d clang-tidy....... 2020-12-22 10:25:45 +03:00
Alexander Kuzmenkov
919172f9ee more fuzzer fixes 2020-12-22 07:16:56 +03:00
Alexander Kuzmenkov
dadfc76f8f fix the fuzzer 2020-12-22 07:02:39 +03:00
Alexander Kuzmenkov
5e19eaf2f0 Merge remote-tracking branch 'origin/master' into tmp 2020-12-18 03:49:59 +03:00
Alexander Kuzmenkov
157fe3e8b4 some tests + ability to echo the queries 2020-12-18 03:49:18 +03:00
Alexander Kuzmenkov
fc426807a8 formatting & fuzzer support 2020-12-18 03:21:23 +03:00
nikitamikhaylov
5521abba1e fix boost 2020-12-16 15:57:42 +03:00
Maksim Kita
963ee5211b Added queries-file parameter. Fixed code review issues 2020-12-07 19:29:17 +03:00
Maksim Kita
f5d1a9e59a Clickhouse client and local added queries-file parameter 2020-12-07 19:29:17 +03:00
Alexander Kuzmenkov
1570320e20 fixes for context hierarchy 2020-11-18 20:43:18 +03:00
alexey-milovidov
8dd81410de
Merge pull request #16843 from azat/clickhouse-client-stage
Add --stage option for clickhouse-client
2020-11-12 13:09:40 +03:00
Alexander Tokmakov
dbac7860b1 review suggestions 2020-11-11 16:27:54 +03:00
Azat Khuzhin
ab8f13b885 Add --stage option for clickhouse-client
It is sometimes useful to process queries not up to the Complete stage
but intermediate some (i.e. for Distributed queries debugging and
similar).
2020-11-11 00:54:51 +03:00
Alexander Tokmakov
b94cc5c4e5 remove more stringstreams 2020-11-10 21:22:26 +03:00
Alexander Tokmakov
5cdfcfb307 remove other stringstreams 2020-11-09 22:12:44 +03:00
Alexander Tokmakov
62ff00ee8b use WriteBuffer in formatAST(...) 2020-11-09 19:05:40 +03:00
Alexander Kuzmenkov
24e57c659a
Merge pull request #15960 from kitaisreal/clickhouse-client-added-history-file-parameter
Clickhouse client added history file parameter
2020-11-09 08:19:00 +03:00
Maksim Kita
05ba70c91f Clickhouse client added history file parameter 2020-11-06 17:05:59 +03:00
Alexey Milovidov
5cfd84249b Merge branch 'master' into register-formats 2020-11-04 12:41:59 +03:00
Ivan
281bf351d2
Remove ANALYZE and AST queries (#16536) 2020-11-02 15:47:12 +03:00
Alexey Milovidov
2e0a979e3a Fix inconsistency in FormatFactory 2020-10-29 06:39:43 +03:00
Alexey Milovidov
c703c052b4 Merge branch 'master' into suggest-destruction-order 2020-10-28 04:21:43 +03:00
Alexander Kuzmenkov
5a70e26c70 Merge remote-tracking branch 'origin/master' into HEAD 2020-10-26 19:21:13 +03:00
Alexey Milovidov
4bf32cb15b Fix destruction order of Suggest #16035 2020-10-25 05:07:52 +03:00
Ivan
1d170f5745
ASTTableIdentifier Part #1: improve internal representation of ASTIdentifier name (#16149)
* Use only |name_parts| as primary name source

* Restore legacy logic for table restoration

* Fix build

* Fix tests

* Add pytest server config

* Fix tests

* Fixes due to review
2020-10-24 21:46:10 +03:00
Alexander Kuzmenkov
84908df6d8 fix setting parent from HTTP traceparent 2020-10-20 14:35:13 +03:00
Alexander Kuzmenkov
036cdd33c5 reset error code in ast fuzzer 2020-10-16 17:27:47 +03:00
Alexander Kuzmenkov
9116a00a12 reset error code in ast fuzzer 2020-10-16 17:26:59 +03:00
Alexander Kuzmenkov
6200433e12 Merge origin/master into tmp (using imerge) 2020-10-12 21:15:31 +03:00
Amos Bird
e2643d881e
Prettify 2020-10-12 00:12:36 +08:00
alexey-milovidov
1aafa19146
Update Client.cpp 2020-10-11 13:27:09 +03:00
Amos Bird
ff665c362f
Add print query id support to client 2020-10-11 10:09:08 +08:00
alesapin
17b86dec96 Recursive defaults 2020-10-02 15:38:50 +03:00
Alexander Kuzmenkov
218d86de7e Merge remote-tracking branch 'origin/master' into tmp 2020-09-28 16:29:51 +03:00
Alexey Milovidov
57b480e65d Fix PVS warning 2020-09-26 07:03:55 +03:00
Alexander Kuzmenkov
7b64ca33b1 Merge remote-tracking branch 'origin/master' into tmp 2020-09-22 14:02:20 +03:00
Alexander Kuzmenkov
bfc3be9e43 Merge remote-tracking branch 'origin/aku/tcp-versio' into tmp 2020-09-22 14:02:15 +03:00
Alexander Kuzmenkov
e97c9b16a7 more diagnostics in fuzzer 2020-09-22 13:35:28 +03:00
alexey-milovidov
cf5db5e4dc
Merge pull request #14888 from azat/client-imporove-INSERT-error-message
Improve error message for INSERT via clickhouse-client
2020-09-18 01:13:22 +03:00
Vitaly Baranov
3356d75b23
Merge pull request #13156 from azat/cluster-secure
Secure inter-cluster query execution (with initial_user as current query user) [v3]
2020-09-17 17:11:00 +03:00
Alexander Kuzmenkov
6217dd77b5 Merge remote-tracking branch 'origin/master' into tmp 2020-09-17 12:35:10 +03:00
Azat Khuzhin
7d046b24e6 Improve error message for INSERT via clickhouse-client
With '\n...' after the query [1] clickhouse-client prefer data from the
INSERT over from stdin, and produce very tricky message:

    Code: 27. DB::Exception: Cannot parse input: expected '\n' before: ' ': (at row 1)

Well for TSV it is ok, but for RowBinary:

    Code: 33. DB::Exception: Cannot read all data. Bytes read: 1. Bytes expected: 4.

So improve error message by adding the source of data for INSERT.

  [1]: clickhouse-client -q "INSERT INTO data FORMAT TSV\n " <<<2
2020-09-17 00:16:51 +03:00
Azat Khuzhin
0159c74f21 Secure inter-cluster query execution (with initial_user as current query user) [v3]
Add inter-server cluster secret, it is used for Distributed queries
inside cluster, you can configure in the configuration file:

  <remote_servers>
      <logs>
          <shard>
              <secret>foobar</secret> <!-- empty -- works as before -->
              ...
          </shard>
      </logs>
  </remote_servers>

And this will allow clickhouse to make sure that the query was not
faked, and was issued from the node that knows the secret. And since
trust appeared it can use initial_user for query execution, this will
apply correct *_for_user (since with inter-server secret enabled, the
query will be executed from the same user on the shards as on initator,
unlike "default" user w/o it).

v2: Change user to the initial_user for Distributed queries if secret match
v3: Add Protocol::Cluster package
v4: Drop Protocol::Cluster and use plain Protocol::Hello + user marker
v5: Do not use user from Hello for cluster-secure (superfluous)
2020-09-15 01:36:28 +03:00
Alexander Tokmakov
da6beb1a91 Merge branch 'master' into enable_some_tests_with_database_atomic 2020-09-14 23:00:14 +03:00
Alexander Kuzmenkov
d227f1f706
Merge pull request #13192 from ClickHouse/aku/semicolon-simple
Simpler version of semicolon-terminated VALUES #12999 w/o `pos` changes
2020-09-11 11:51:52 +03:00
Alexander Kuzmenkov
83ec93dec8 Fuzzer: reset default database before reconnect 2020-09-09 16:46:59 +03:00
Alexander Tokmakov
b68782d285 enable more tests with Atomic database 2020-09-09 16:32:50 +03:00
Alexander Kuzmenkov
c62bf555d2 Merge origin/master into tmp (using imerge) 2020-09-08 16:26:38 +03:00
Alexander Kuzmenkov
9cf2a38eb8 fixup 2020-09-01 03:22:06 +03:00
Alexander Kuzmenkov
33c5815eb3 Add a HTML report for AST Fuzzer 2020-09-01 02:33:42 +03:00