Commit Graph

161 Commits

Author SHA1 Message Date
zwangsheng
3bc299d01e
[KYUUBI #2868] [K8S] Add KubernetesApplicationOperation
### _Why are the changes needed?_

close #2868
Add Kubernetes Application Operation.
Help Tag Spark Driver with Engine Ref Id.

1) Find taged Engine:
`KyuubiApplicationManager => KubernetesApplicationOperation =(doesn't found taged pod)=> KubernetesApplicationOperation#JpsApplicationOperation`

2) `SparkBatchProcessBuilder` add logic to help tag Kubernetes Engine Tag.

3) Add Unit Test help to check `KubernetesApplicationOperation` find & kill  Spark Engine On Kubernetes with both client mode and cluster mode.

### _How was this patch tested?_
- [x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2869 from zwangsheng/feature/k8s-application-operation.

Closes #2868

04c97210 [zwangsheng] remove
fc151603 [zwangsheng] fix kyuubi on kubernetes integration test
29a3da52 [zwangsheng] fix
f43f0989 [zwangsheng] fix
2f2c9581 [zwangsheng] test
209dd65d [zwangsheng] fix jps
e12c681c [zwangsheng] fix tag
80971f98 [zwangsheng] fix
0760b63d [zwangsheng] fix
087eadb1 [zwangsheng] fix
d4989b09 [zwangsheng] try
93d83f81 [zwangsheng] add test
19378da4 [zwangsheng] fix style
63007261 [zwangsheng] fix test
fd4bf714 [zwangsheng] fix
66fc902b [zwangsheng] Using jps for client
2a1b797f [zwangsheng] fix setting
4827c459 [zwangsheng] fix
9ee90da6 [zwangsheng] decoupling spark
6b5831da [zwangsheng] useless driver label
f9ca898c [zwangsheng] fix
2add72fe [zwangsheng] fix setting
aaa081f8 [zwangsheng] fix style & dependency list
e102ac73 [zwangsheng] add kubernetesApplicationOperation

Authored-by: zwangsheng <2213335496@qq.com>
Signed-off-by: ulysses-you <ulyssesyou@apache.org>
2022-07-01 12:15:12 +08:00
Fei Wang
6f308c434c [KYUUBI #2964] [SUB-TASK][KPIP-4] Refine the batch response and render
### _Why are the changes needed?_

This is make some enhancements for batch response:
- combine batch name and batch app name
- flatten the batchInfo map to `appId`, `appUrl`, `appState` and`appDiagnostic`

Using https://github.com/JakeWharton/flip-tables for table render, which support that the column value could be a multiple-line string.
### _How was this patch tested?_
- [x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [x] Add screenshots for manual tests if appropriate

Batch List:
![image](https://user-images.githubusercontent.com/6757692/176608602-89082758-4170-4337-ae64-b0dc75eaba77.png)

Batch Report:
![image](https://user-images.githubusercontent.com/6757692/176608636-448edf13-3147-4fc7-9df5-0192841f4201.png)

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2964 from turboFei/refine_batch_resp.

Closes #2964

deaedcbc [Fei Wang] add into LICENSE-binary
1f9691e3 [Fei Wang] [SUB-TASK][KPIP-4] Refine the batch response and render

Authored-by: Fei Wang <fwang12@ebay.com>
Signed-off-by: Fei Wang <fwang12@ebay.com>
2022-06-30 18:27:45 +08:00
Cheng Pan
3435e2ae49
[KYUUBI #2915] Revert "[KYUUBI #2000][DEPS] Bump Hadoop 3.3.2"
### _Why are the changes needed?_

https://github.com/apache/incubator-kyuubi/issues/2904
This reverts commit e250c4ae35.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2915 from pan3793/revert.

Closes #2915

Closes #2000

9c789eb1 [Cheng Pan] Revert "[KYUUBI #2000][DEPS] Bump Hadoop 3.3.2"

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-06-21 02:18:09 +08:00
Cheng Pan
2fd4e3a858
[KYUUBI #2827] [BUILD][TEST] Decouple integration tests from kyuubi-server
### _Why are the changes needed?_

This PR moves engine integration tests except to spark engine from `kyuubi-server` module to dedicated IT modules e.g. `kyuubi-hive-it`, then we can spilt different engine test into jobs to speed up CI tes

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [x] Add screenshots for manual tests if appropriate

before
<img width="836" alt="image" src="https://user-images.githubusercontent.com/26535726/173265839-5d0f1ce6-e133-4d60-9a95-c95aa16f817f.png">

after
<img width="825" alt="image" src="https://user-images.githubusercontent.com/26535726/173265903-fb01e910-8f78-4091-91da-dca25be4357d.png">

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2827 from pan3793/hive-it.

Closes #2827

df3798f1 [Cheng Pan] Remove Java 11 test for Hive
e1645338 [Cheng Pan] nit
66524226 [Cheng Pan] nit
3aef2cef [Cheng Pan] review
500c9cff [Cheng Pan] MVN_OPT
3b4ad142 [Cheng Pan] nit
daa6e0ab [Cheng Pan] review
3383d4c1 [Cheng Pan] [BUILD][TEST] Decouple integration tests from kyuubi-server

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-06-18 00:01:34 +08:00
zhouyifan279
bdceaaf1f6
[KYUUBI #2883] [Bug] java.lang.NoClassDefFoundError: org/apache/hadoop/hive/common/ValidWriteIdList in HiveDelegationTokenProvider#initialize
### _Why are the changes needed?_
Fix #2879

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2883 from zhouyifan279/2879.

Closes #2883

bbd6c2e7 [zhouyifan279] [Bug] java.lang.NoClassDefFoundError: org/apache/hadoop/hive/common/ValidWriteIdList in HiveDelegationTokenProvider#initialize
d5046f36 [zhouyifan279] [Bug] java.lang.NoClassDefFoundError: org/apache/hadoop/hive/common/ValidWriteIdList in HiveDelegationTokenProvider#initialize

Authored-by: zhouyifan279 <zhouyifan279@gmail.com>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-06-14 23:30:49 +08:00
Fu Chen
6cd2ad9ef7
[KYUUBI #2780] Refine stylecheck
### _Why are the changes needed?_

1. reformat code should include all of the modules in the project.
2. stylecheck should include all of the modules in the project.
3. there is a bug in the stage `Upload style check report`.

Since the `grep` returns code 1 when the pattern is not found, the upload report does not work before this pr.

```
> echo "a" > /tmp/a; grep abc /tmp/a; echo $?
1
```

Before this PR
```
Run for log in `find * -name "scalastyle-output.xml"`;  do echo "=========$log========="; grep "error" $log; done
=========dev/kyuubi-tpcds/target/scalastyle-output.xml=========
Error: Process completed with exit code 1.
```

After this PR
```
Run for log in `find * -name "scalastyle-output.xml"`;
<?xml version="1.0" encoding="UTF-8"?>
<checkstyle version="5.0">
 <file name="/home/runner/work/incubator-kyuubi/incubator-kyuubi/extensions/spark/kyuubi-extension-spark-3-3/src/main/scala/org/apache/kyuubi/sql/KyuubiSparkSQLExtension.scala">
  <error column="0" line="21" source="org.scalastyle.scalariform.ImportOrderChecker" severity="error" message="There should at least one a single empty line separating groups 3rdParty and kyuubi."/>
 </file>
</checkstyle>
```

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2780 from cfmcgrady/refine-stylecheck.

Closes #2780

a9c4a71e [Fu Chen] update reformat
f5d4d4e4 [Fu Chen] address comment
0665e7e5 [Fu Chen] address
91d123ee [Fu Chen] fix
f5d6414f [Fu Chen] style.yml
c56fa081 [Fu Chen] dev/reformat

Authored-by: Fu Chen <cfmcgrady@gmail.com>
Signed-off-by: ulysses-you <ulyssesyou@apache.org>
2022-06-01 16:49:01 +08:00
Fei Wang
73c6b1b14a [KYUUBI #2717] [SUB-TASK][KPIP-4] Introduce jdbc session state store for batch session multiple HA
### _Why are the changes needed?_

Close #2715
Close #2374
Introduce jdbc based session state store to share the batch state information across kyuubi instances.

This pr is based on docs: https://docs.google.com/document/d/1_BMekMT88P2vCHCl4ZacWEeWslpIv4pxsJH32PAnWSI and  refactor it during implementation.

In this PR, I introduce `StateStore` interface and implement the default `JDBCStateStore`.

The data structures:
1. BatchState - the batch state info for multiple-HA, including batch operation state and application information
2. BatchMeta - the meta data used for batch recovery, including sessionConf, batchRequest information

For JDBCStateStore:
- support to specify data base type:
  - 1. DERBY - it will use derby jdbc driver by default
  - 2. MYSQL - it will use mysql jdbc by default
  - 3. CUSTOM - the user need specify the jdbc driver
- support to init schema

By default, the jdbc url is a derby in-memory database url for single kyuubi instance.

To support multiple HA in production env, we should config the production jdbc url to share batch info across kyuubi instances.

The datasource is managed by HiKariCP.

### _How was this patch tested?_
- [x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2717 from turboFei/kyuubi_2715_hikaricp_v2.

Closes #2717

367b944a3 [Fei Wang] comments
9a7963dbd [Fei Wang] post session type in event
b1c130853 [Fei Wang] move session type to session package
66def0cb6 [Fei Wang] add JDBCStateStoreConf
839b72bf6 [Fei Wang] refactor
644cbcd28 [Fei Wang] filter by session type
58f1c7854 [Fei Wang] refactor
1c0035208 [Fei Wang] add session type
34a087ee5 [Fei Wang] refactor
fba38e473 [Fei Wang] refactor
fcbde25a0 [Fei Wang] refactor
332a67537 [Fei Wang] comments
135ba9b6d [Fei Wang] Revert "revert class utils change"
0e045a483 [Fei Wang] Revert "Revert "move""
05048416e [Fei Wang] Revert "test again"
01a50c35b [Fei Wang] test again
b89159d13 [Fei Wang] Revert "move"
3764a9051 [Fei Wang] move
eef17822c [Fei Wang] revert
4166db261 [Fei Wang] adjust engine idle timeout
5fc95a824 [Fei Wang] revert class utils change
23f88d63d [Fei Wang] refactor
a66cb811d [Fei Wang] refactor
89fa0edb4 [Fei Wang] fix
e5228fefd [Fei Wang] refactor
581908d86 [Fei Wang] exclude sql
3446aaa06 [Fei Wang] UPPER
ab980c677 [Fei Wang] [KYUUBI #2715] Introduce session state store for batch session multiple HA

Authored-by: Fei Wang <fwang12@ebay.com>
Signed-off-by: Fei Wang <fwang12@ebay.com>
2022-05-31 15:06:39 +08:00
Tianlin Liao
b817fcf76a [KYUUBI #2643] [SUB-TASK][KPIP-4] Implement kyuubi rest sdk for batch job operation
### _Why are the changes needed?_

To close #2643

### _How was this patch tested?_
- [x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2723 from lightning-L/kyuubi-2643.

Closes #2643

b7c409bcf [Tianlin Liao] unify junit dependency
ae2caca33 [Tianlin Liao] implements AutoClosable for KyuubiRestClient; rename server in rest builder to spnego builder
19e078a32 [Tianlin Liao] reuse ObjectMapper
ef98f4c2a [Tianlin Liao] minor improvements
15d958acf [Tianlin Liao] unify httpclient version parameter
37032a6a9 [Tianlin Liao] fix dependency
6c97745aa [Tianlin Liao] support NONE and NOSASL basic auth type
aa0a1c011 [Tianlin Liao] add optional tag for hadoop-client-api/hadoop-client-runtime
275d1d042 [Tianlin Liao] add integration test in kyuubi-server
b407d0229 [Tianlin Liao] apiBasePath is not necessary for the client builder
db11f10eb [Tianlin Liao] add test case for http response code is not 200
361343fe0 [Tianlin Liao] add builder arguments validation
a2684de86 [Tianlin Liao] remove gson dependency; fix get log api typo
ed3498938 [Tianlin Liao] Define KyuubiRestException and remove kyuubi-common dependency
b46f0c4d3 [Tianlin Liao] add AuthScheme config in Builder
61796d782 [Tianlin Liao] fix sun.security does not exist/not visible error
de9bb26e2 [Tianlin Liao] [KYUUBI #2643] [SUB-TASK][KPIP-4] Implement kyuubi rest sdk for batch job operation

Authored-by: Tianlin Liao <tiliao@ebay.com>
Signed-off-by: Fei Wang <fwang12@ebay.com>
2022-05-29 08:40:33 +08:00
jiaoqingbo
a8943bc3b0
[KYUUBI #2736] Upgrade Jackson 2.13.3
### _Why are the changes needed?_

fix #2736

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2739 from jiaoqingbo/kyuubi-2736.

Closes #2736

00c8c618 [jiaoqingbo] fix ut failed
56a7b4ef [jiaoqingbo] fix failed
00184fc2 [jiaoqingbo] fix failed
11647f21 [jiaoqingbo] [KYUUBI #2736] Upgrade Jackson 2.13.3

Authored-by: jiaoqingbo <1178404354@qq.com>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-05-26 10:26:46 +08:00
Cheng Pan
aa4ac58ce5
[KYUUBI #2702] Fix TPC-DS columns name and add TPC-DS queries verification
### _Why are the changes needed?_

As there are some issues with the TPC-DS column name reported in https://github.com/trinodb/tpcds/pull/2, we need a workaround before the upstream patch release is available.

This PR also introduces the option `useTableSchema_2_6`(default is `true`), user can set `false` to make the column name compatible with old TPC-DS queries.

Close #2679

### _How was this patch tested?_
- [x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2702 from pan3793/tpcds-fix-colname.

Closes #2702

82503711 [Cheng Pan] Rename conf
fb007ed7 [Cheng Pan] tpcds 3.2
5ebf8691 [Cheng Pan] Fix TPC-DS columns name

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-05-19 17:02:48 +08:00
Fei Wang
31fdd7ec46 [KYUUBI #2668] [SUB-TASK][KPIP-4] Rewrite the rest DTO classes in java
### _Why are the changes needed?_

To close #2674
Rewrite the rest DTO classes in java, which is the preparation for kyuubi rest sdk #2643

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2668 from turboFei/client_do.

Closes #2668

e2bf779c [Fei Wang] revert by reformat
a23f65f6 [Fei Wang] address comments
6648ef90 [Fei Wang] regen the equals & hashCode without accepct subclasses as parameter to equals()
840866c9 [Fei Wang] add equals & hashCode for dto classes
1cc9afaa [Fei Wang] return empty collections
2d49db50 [Fei Wang] return empty batch info map by defaults
1bb399c0 [Fei Wang] only reserve slf4j-api
c6621ed8 [Fei Wang] fix ut
e15ea9f0 [Fei Wang] refactor
ef6dc16c [Fei Wang] add dependes into assembly
ffacf68d [Fei Wang] rewrite the dto classes in java

Authored-by: Fei Wang <fwang12@ebay.com>
Signed-off-by: Fei Wang <fwang12@ebay.com>
2022-05-17 17:59:38 +08:00
gabrywu
a6e14ac38d [KYUUBI #2560] Upgrade kyuubi-hive-jdbc hive version to 3.1.3
### Why are the changes needed?

upgrade hive to 3.1.3 in the kyuubi-hive-jdbc module

### change details

file|comment
--- | ---
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/HttpBasicAuthInterceptor.java | add customCookies as a construct parameter
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/HttpKerberosRequestInterceptor.java | replace assumeSubject field with `Subject loggedInSubject` ; add customCookies as a construct parameter
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/HttpRequestInterceptorBase.java | add customCookies as a construct parameter; add customCookies initialization codes
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/HttpTokenAuthInterceptor.java | add customCookies as a construct parameter
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/JdbcColumn.java | support TIMESTAMP_WITH_TIMEZONE & UNION_TYPE type
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/KyuubiBaseResultSet.java | support TIMESTAMPLOCALTZ_TYPE
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/KyuubiConnection.java | add loggedInSubject,wmPool & wmApp fields and their initialization codes; add getAllUrls function; use Utils.getCanonicalHostName to extract host from connParams; clear hive conf in embedded mode; use SessionUtils.getTokenStrForm to get token string; remove isZkDynamicDiscoveryMode
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/KyuubiDatabaseMetaData.java | support getSQLKeywords; add Object class type parameter to KyuubiMetaDataResultSet
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/KyuubiMetaDataResultSet.java | optimize initialization logic of data & columnTypes field; add normalizeColumnNames function
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/KyuubiStatement.java | split closeClientOperation into 2 functions(closeStatementIfNeeded & closeClientOperation) & add reInitState function to replace initFlags & ad error messages to exceptions in CANCELED_STATE
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/Utils.java | add dummyAuthorityString, SERVICE_DISCOVERY_MODE_ZOOKEEPER_HA, ZOOKEEPER_ACTIVE_PASSIVE_HA_DEFAULT_NAMESPACE, WM_POOL, HTTP_COOKIE_PREFIX, APPLICATION fields; replace authorityList field with suppliedURLAuthority in JdbcConnectionParams;add a construct function to JdbcConnectionParams; replace getAuthorityList function with getSuppliedURLAuthority; split parseURL into 2 different functions(parseURL, extractURLComponents); add configureConnParamsFromZooKeeper, handleAllDeprecations, getAuthorityFromJdbcURL functions; remove configureConnParams;remove joinStringArray;add getCanonicalHostName function
kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/ZooKeeperHiveClientHelper.java | add more functions
kyuubi-server/src/main/resources/META-INF/services/org.apache.hadoop.security.token.TokenIdentifier | change package name of DelegationTokenIdentifier
kyuubi-server/src/main/scala/org/apache/kyuubi/credentials/HiveDelegationTokenProvider.scala | change package name of DelegationTokenIdentifier
kyuubi-server/src/test/scala/org/apache/kyuubi/credentials/HiveDelegationTokenProviderSuite.scala | add configs, METASTORE_CONNECTION_POOLING_TYPE = none,METASTORE_AUTO_CREATE_ALL = true, METASTORE_SCHEMA_VERIFICATION = false; add construct parameter clientConf to HadoopThriftAuthBridgeWithServerContextClassLoader
kyuubi-common/src/test/scala/org/apache/kyuubi/operation/SparkMetadataTests.scala | remove getSQLKeywords from unsupported list
externals/kyuubi-hive-sql-engine/pom.xml | add HikariCP to test scope
pom.xml | update hive version to 3.1.3
kyuubi-hive-jdbc-shaded/pom.xml | add hive-standalone-metastore dependency; add hive-llap-client dependency
kyuubi-hive-jdbc/pom.xml | add hive-standalone-metastore dependency;add hive-llap-client dependency
kyuubi-server/pom.xml | add hive-standalone-metastore dependency
dev/dependencyList | add hive-standalone-metastore
kyuubi-hive-jdbc-shaded/src/main/resources/META-INF/LICENSE | update content because of hive-standalone-metastore & hive-llap-client
kyuubi-hive-jdbc-shaded/src/main/resources/META-INF/NOTICE | update content because of hive-standalone-metastore & hive-llap-client

### How was this patch tested?

use existing UTs to test this patch

Closes #2560 from gabrywu/jdbc-3.1.

Closes #2560

9c5e3eda [gabry.wu] Merge branch 'master' into jdbc-3.1
c23cefc5 [gabrywu] update NOTICE rollback unnecessary change
b9394144 [gabrywu] change hikaricp.version position to satisfy alphabetical order
59ebed37 [gabrywu] add hive-storage-api explicitly
d22dc585 [gabrywu] rollback to minimize diff of this PR
33c13f0f [gabrywu] update LICENSE, NOTICE, LICENSE add hive-llap-client to kyuubi-hive-jdbc-shaded module
d1ce2c6c [gabrywu] manage hikaricp.version under dependencyManagement
1f4b7c72 [gabrywu] Merge remote-tracking branch 'origin/jdbc-3.1' into jdbc-3.1
fd309054 [gabrywu] manage hikaricp.version under dependencyManagement
39aa7ae6 [gabrywu] manage hikaricp.version under dependencyManagement
85dc983a [gabrywu] manage hikaricp.version under dependencyManagement
545578c5 [gabrywu] update dependencyList file
f479f642 [gabrywu] remove optional flag of hive-standalone-metastore in kyuubi-server
5ee8f89b [gabrywu] 1. add hive-storage-api 2. enable METASTORE_AUTO_CREATE_ALL 3. disable METASTORE_SCHEMA_VERIFICATION
f70b0354 [gabrywu] add HikariCP to test scope
c93ab167 [gabrywu] set METASTORE_CONNECTION_POOLING_TYPE to none
feb53d6e [gabrywu] support getSQLKeywords func
4601b9b9 [gabrywu] exclude package.jdo
4f4a19bf [gabrywu] upgrade hive version to 3.3.1 in dependencyList
0b88a77a [gabrywu] upgrade hive to 3.1.3

Lead-authored-by: gabrywu <gabrywu@apache.org>
Co-authored-by: gabry.wu <gabrywu@apache.org>
Signed-off-by: Fei Wang <fwang12@ebay.com>
2022-05-09 22:05:22 +08:00
Cheng Pan
3ecdd42286
[KYUUBI #2439] Using Pure Java TPC-DS generator
### _Why are the changes needed?_

This PR proposes change the Kyuubi TPC-DS generator to pure Java implementation instead of the original C binary.

The new pure Java TPC-DS generator is under Apache License, and in fact, I don't know the original C binary License, so we exclude them from release in the past.

Since the change removes the License issue of Kyuubi TPC-DS module, we can bundle the TPC-DS tool in the future release.

And after migration, I haven't see "error=26, Text file busy" described in #2439 any more.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [x] Add screenshots for manual tests if appropriate

1. Use old C binary based TPC-DS generator generate 1GB data under database `tpcds_s1`
2. Use new pure Java base TPC-DS generator generate 1GB data under database `new_tpcds_sf1`
3. Compare results of `select count(*)`, and `select sum(hash(*))`

```
spark-sql> select count(*) from tpcds_s1.inventory;
11745000
Time taken: 0.161 seconds, Fetched 1 row(s)
spark-sql> select count(*) from new_tpcds_sf1.inventory;
11745000
Time taken: 0.141 seconds, Fetched 1 row(s)
spark-sql> select sum(hash(*)) from tpcds_s1.inventory;
-556768665838
Time taken: 0.252 seconds, Fetched 1 row(s)
spark-sql> select sum(hash(*)) from new_tpcds_sf1.inventory;
-556768665838
Time taken: 0.232 seconds, Fetched 1 row(s)
```

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2449 from pan3793/tpcds.

Closes #2439

a270bcba [Cheng Pan] Remove the exclusion in source release
7c8d3271 [Cheng Pan] [KYUUBI #2439] Using Pure Java TPC-DS generator

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Kent Yao <yao@apache.org>
2022-04-24 11:03:55 +08:00
Min Zhao
d851b23a60
[KYUUBI #2323] Separate events to a submodule - kyuubi-event
### _Why are the changes needed?_

Separate events to a submodule - kyuubi-event

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2392 from zhaomin1423/event-module.

Closes #2323

7efa923f [Min Zhao] fix unit test
07126f43 [Min Zhao] [KYUUBI #2323] Separate events to a submodule - kyuubi-event
cccbdf11 [Min Zhao] [KYUUBI #2323] Separate events to a submodule - kyuubi-event
194aca82 [Min Zhao] add shade and log4j to test/resources
f75891a1 [Min Zhao] [KYUUBI #2323] Separate events to a submodule - kyuubi-event
357395fa [Min Zhao] [KYUUBI #2323] Separate events to a submodule - kyuubi-event
b6dfd186 [Min Zhao] [KYUUBI #2323] Separate events to a submodule - kyuubi-event
fc876688 [Min Zhao] [KYUUBI #2323] Separate events to a submodule - kyuubi-event
1b86d41b [Min Zhao] seperate event

Authored-by: Min Zhao <zhaomin1423@163.com>
Signed-off-by: Kent Yao <yao@apache.org>
2022-04-19 12:06:23 +08:00
Ada Wang
ff1bb5551f
[KYUUBI #2317][BUILD] Bump hive-service-rpc 3.1.3 version
### _Why are the changes needed?_

Bump hive-service-rpc 3.1.3 version

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2318 from deadwind4/2317-hive-rpc.

Closes #2317

93cf3b38 [Ada Wang] [KYUUBI #2317][BUILD] Bump hive-service-rpc 3.1.3 version

Authored-by: Ada Wang <wang4luning@gmail.com>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-04-11 12:07:27 +08:00
ulysses-you
82a024a983
[KYUUBI #2292] Unify spark extension location
### _Why are the changes needed?_

Move `dev/kyuubi-spark-extension*` to `extension/spark/`

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2291 from ulysses-you/unify-spark-extension.

Closes #2292

4e6f4ca6 [ulysses-you] fix
c2cc018d [ulysses-you] unify
2375af0d [ulysses-you] unify

Authored-by: ulysses-you <ulyssesyou18@gmail.com>
Signed-off-by: ulysses-you <ulyssesyou@apache.org>
2022-04-07 13:58:58 +08:00
zwangsheng
0fd4738146
[KYUUBI #2246] [BUILD] Pick Commons-Logging dependence out of Hudi-Common
### _Why are the changes needed?_

```
        <dependency>
            <groupId>org.apache.hadoop</groupId>
            <artifactId>hadoop-client-minicluster</artifactId>
            <scope>test</scope>
        </dependency>
```
`hadoop-client-minicluster` need `commons-logging` dependence. Now it works because `hudi-spark-common` include this dependency.

We extract it to better manage dependencies.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2246 from zwangsheng/fix/pick_commons_logging_dependice.

Closes #2246

5e75b964 [zwangsheng] update LICENSE
76913f15 [zwangsheng] recover unnecessary change
5fb2f3a6 [zwangsheng] rebuild dependency list
2979a3cd [zwangsheng] fix
42ae31c5 [zwangsheng] remove common-logging
d0d6401e [zwangsheng] replace
ff306b3f [zwangsheng] Pick Commons-Logging Dependices Out of Hudi

Authored-by: zwangsheng <2213335496@qq.com>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-03-31 18:22:15 +08:00
Kent Yao
513ea83438
[KYUUBI #1451] Introduce Kyuubi Spark AuthZ Module with column-level fine-grained authorization
### _Why are the changes needed?_

 - #1451

### Kyuubi Spark AuthZ Extension

#### Functions

- [x] Column-level fine-grained authorization
- [ ] Row-level fine-grained authorization, a.k.a. Row-level filtering
- [ ] Data masking

#### Build

```shell
build/mvn clean package -pl :kyuubi-spark-authz_2.12 -Dspark.version=3.2.1 -Dranger.version=2.2.0
```

#### Supported Apache Spark Versions

`-Dspark.version=`

- [x] master
- [x] 3.3.x
- [x] 3.2.x (default)
- [x] 3.1.x
- [x] 3.0.x
- [x] 2.4.x
- [ ] 2.3.x and earlier

#### Supported Apache Ranger Versions

`-Dranger.version=`

- [x] 3.0.0-SNAPSHOT
- [x] 2.2.x (default)
- [x] 2.1.x
- [x] 2.0.x
- [x] 1.2.x
- [x] 1.1.x
- [x] 1.0.x
- [x] 0.7.x
- [x] 0.6.x

### TODO LIST
- [ ] Doc
- [ ] Auditing
- [ ] Support row-level filtering
- [ ] Support Data masking
- [ ] Support v2 DDLs
- [ ] Support Custom Commands like create hudi table etc.

### _How was this patch tested?_
- [x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2160 from yaooqinn/1451.

Closes #1451

3ae4a833 [Kent Yao] nit
c8ab1ef0 [Kent Yao] nit
68e71ac7 [Kent Yao] readme
1a1dc994 [Kent Yao] style
f5fda710 [Kent Yao] support Spark 2.4.7
d1d5318e [Kent Yao] support ranger 0.6
6e57ce3b [Kent Yao] support ranger 0.7
f0dce7ce [Kent Yao] minor
120c6e3e [Kent Yao] Update extensions/spark/kyuubi-spark-authz/src/main/scala/org/apache/kyuubi/plugin/spark/authz/ranger/AccessResource.scala
06f73e99 [Kent Yao] add comments
344e3a8f [Kent Yao] simpler
cffabce7 [Kent Yao] rm dead code
ec5edae7 [Kent Yao] rm dead code
1384f2b6 [Kent Yao] rm log4j 1
a6c0d0bb [Kent Yao] reduce configs
06c0452b [Kent Yao] deps
cf599e15 [Kent Yao] ranger tests
3adc6cf4 [Kent Yao] ranger tests
94a841ee [Kent Yao] ranger tests
c5af35fd [Kent Yao] starting working on ranger
5cb52e3a [Kent Yao] queries
5318dca2 [Kent Yao] clear cache before each
3427b679 [Kent Yao] join inner
cfada65d [Kent Yao] show
4dca5cfa [Kent Yao] show clos
a2d02ae0 [Kent Yao] truncate table
7424ad0c [Kent Yao] set db & desc db
046ac025 [Kent Yao] desc table & col
caaaf619 [Kent Yao] DescribeColumnCommand
77b2efcf [Kent Yao] drop/refresh function
716e05be [Kent Yao] create function
0d3dc247 [Kent Yao] create function
666e4d4f [Kent Yao] Create table as select
e9aaa0e9 [Kent Yao] Create table
3a2389a2 [Kent Yao] Create View
395ec13f [Kent Yao] CacheTableAsSelect
1544f818 [Kent Yao] fix
4bb9c624 [Kent Yao] more tests
aa134ade [Kent Yao] alter view as
131d95bb [Kent Yao] alter view as
b1722d7e [Kent Yao] test & opt
01ba1585 [Kent Yao] build default
f9811b0d [Kent Yao] test add
a9c044ac [Kent Yao] test
14685630 [Kent Yao] test
6c0b5ed9 [Kent Yao] format
810f9992 [Kent Yao] [WIP] Migrate Spark security module from submarine to kyuubi
a3fd5d20 [Kent Yao] [WIP] Migrate Spark security module from submarine to kyuubi
3fe1bf4c [Kent Yao] [WIP] Migrate Spark security module from submarine to kyuubi
d16a0c3c [Kent Yao] [WIP] Migrate Spark security module from submarine to kyuubi

Authored-by: Kent Yao <yao@apache.org>
Signed-off-by: Kent Yao <yao@apache.org>
2022-03-31 15:37:40 +08:00
Ada
88e0bcd2a1
[KYUUBI #2197][BUILD] Bump jersey 2.35 version
### _Why are the changes needed?_

Bump jersey 2.35 version

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2200 from deadwind4/bump-jetty.

Closes #2197

5c2d1703 [Ada] [KYUUBI #2197][BUILD] Bump jersey 2.35 version

Authored-by: Ada <wang4luning@gmail.com>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-03-24 11:49:03 +08:00
Kent Yao
3eb1fa9e48
[KYUUBI #2175] Improve CI with cancel & concurrency & paths filter
### _Why are the changes needed?_

Better ASF GHA resource usage, see more https://cwiki.apache.org/confluence/display/BUILDS/GitHub+Actions+status

- cancel-in-progress enabled. w/ this, a previous build can be canceled if new commit(s) have arrived
- style check w/o install. currently, the style check takes 8~10min to finish because an install step before it. now, it shall return within a minute. note that, this might 'fail' itself when we introduce a new module and others depend on it, but it's ok to verify by the log whether a PR ok to be merged.
- dependency check runs only when pom.xml updates. this flow now runs only pom changes as it is the only way that may cause dependency changes.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [x] Add screenshots for manual tests if appropriate

**Canceled**: https://github.com/apache/incubator-kyuubi/runs/5604809742?check_suite_focus=true

<img width="548" alt="image" src="https://user-images.githubusercontent.com/8326978/159059722-480f4fd6-d87e-4b07-984e-eb5b08a84beb.png">

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2175 from yaooqinn/gha.

Closes #2175

33777bc5 [Kent Yao] Update .github/workflows/style.yml
ec41ddd0 [Kent Yao] Update .github/workflows/style.yml
79db981f [Kent Yao] fix
4e1fb387 [Kent Yao] fix
733df9cb [Kent Yao] Improve CI with cancel & concurrency
494c3a84 [Kent Yao] Revert "Improve CI with cancel & concurrency"
57641ac4 [Kent Yao] Improve CI with cancel & concurrency
6dafe970 [Kent Yao] Improve CI with cancel & concurrency
40160ab9 [Kent Yao] Improve CI with cancel & concurrency
377285c2 [Kent Yao] Improve CI with cancel & concurrency
dbe8999e [Kent Yao] Improve CI with cancel & concurrency
78a97260 [Kent Yao] Improve CI with cancel & concurrency
7e984ebd [Kent Yao] Improve CI with cancel & concurrency
d2538210 [Kent Yao] Improve CI with cancel & concurrency
51a7c48c [Kent Yao] Improve CI with cancel & concurrency
c5e3177a [Kent Yao] Improve CI with cancel & concurrency

Authored-by: Kent Yao <yao@apache.org>
Signed-off-by: Kent Yao <yao@apache.org>
2022-03-19 21:06:08 +08:00
Cheng Pan
d7d8b05d4a
[KYUUBI #2134] Respect Spark bundled log4j in extension modules
### _Why are the changes needed?_

As Spark 3.1/3.2 still use log4j 1.2, we should respect Spark bundled log4j in extension modules.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2134 from pan3793/log.

Closes #2134

7429503f [Cheng Pan] Revert "reset mvn log level to info in CI"
694a1597 [Cheng Pan] Revert "mvn --batch-mode"
ba72d84a [Cheng Pan] log4j.properties
39f12c98 [Cheng Pan] mvn --batch-mode
47922266 [Cheng Pan] reset mvn log level to info in CI
b337f719 [Cheng Pan] Respect Spark bundled log4j in extension modules

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Kent Yao <yao@apache.org>
2022-03-15 11:24:22 +08:00
Cheng Pan
f8efcb7125
[KYUUBI #2103] Revert "[KYUUBI #1948] Upgrade thrift version to 0.16.0"
### _Why are the changes needed?_

This PR reverts "[KYUUBI #1948] Upgrade thrift version to 0.16.0" in branch-1.5 and some subsequent commits due to issues caused by breaking changes in Thrift, e.g. #2101, #2093

We need more time to evaluate it and add more test cases to ensure stability before the next release.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2103 from pan3793/revert.

Closes #2103

Closes #1948

575dfe8d [Cheng Pan] properties order
4c94481e [Cheng Pan] fix deps
bfbdeb89 [Cheng Pan] Add log4j deps for kyuubi-hive-jdbc test
bad4e90e [Cheng Pan] surefire
f2ae8b9b [Cheng Pan] Revert "[KYUUBI #1948] Upgrade thrift version to 0.16.0"
4501f743 [Cheng Pan] Revert "[KYUUBI #1948][FOLLOWUP] Remove TFramedTransport in extension-spark-3-1 and extension-spark-3-2"
cc04df49 [Cheng Pan] Revert "[KYUUBI #1996] Clean up log4j2 conf and enhance surefire plugin conf"
52a20e17 [Cheng Pan] Revert "[KYUUBI #1948][FOLLOWUP] Relocate fb303 classes"

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-03-12 21:05:39 +08:00
Fu Chen
9bf8ff83d8
[KYUUBI #2061] Implementation of the very basic UI on current Jetty server
### _Why are the changes needed?_

thanks to the pr original author yaooqinn https://github.com/apache/incubator-kyuubi/pull/1670

After this pr, the endpoint of OpenAPI will change from`http://${ip}:${port}/openapi.json` to `http://${ip}:${port}/api/openapi.json`

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [x] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

![截屏2022-03-08 下午6 10 03](https://user-images.githubusercontent.com/8537877/157215752-b4064adc-4247-42a1-ae28-b4fdf6c6768e.png)

![截屏2022-03-08 下午6 10 31](https://user-images.githubusercontent.com/8537877/157215771-47c13012-3ea7-4fab-bf57-ca36988f2647.png)

Closes #2061 from cfmcgrady/pr-1670.

Closes #2061

969b7d3d [Fu Chen] update dev/dependencyList
ff4b6bc2 [Fu Chen] fix ut
207553b6 [Fu Chen] addressed comment
a3baefe0 [Fu Chen] new line at end of file
ff36f957 [Fu Chen] fix
bb6abb3f [Fu Chen] language
b22be2ec [Fu Chen] style
f0c9562f [Fu Chen] Merge remote-tracking branch 'upstream/master' into pr-1670
d4ac4cba [Fu Chen] fix
cd5ee2b8 [Fu Chen] Merge remote-tracking branch 'upstream/master' into pr-1670
1b108a04 [Kent Yao] ui
85e31519 [Kent Yao] ui
0c20fcff [Kent Yao] ui
c2abde93 [Kent Yao] ui
b4dff513 [Kent Yao] ui
43dffab8 [Kent Yao] Merge branch 'master' into web
7cd273a3 [Kent Yao] swagger ui enabled
518882e2 [Kent Yao] swagger ui enabled

Lead-authored-by: Fu Chen <cfmcgrady@gmail.com>
Co-authored-by: Kent Yao <yao@apache.org>
Signed-off-by: Kent Yao <yao@apache.org>
2022-03-09 10:11:50 +08:00
--replace-all
dc6085e060
[KYUUBI #2043] Upgrade log4j/2.x/ to 2.17.2
### _Why are the changes needed?_

Close #2043

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [x] Add screenshots for manual tests if appropriate

  ![Screenshot from 2022-03-06 19-40-30](https://user-images.githubusercontent.com/87641376/156926866-d673efa7-6c3b-4bf4-a48d-446064513b0b.png)

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2046 from RishiKumarRay/master.

Closes #2043

bf9a4a0b [--replace-all] fixed sql issue
c119e5c2 [Rishi Kumar Ray] Merge branch 'apache:master' into master
323d81c7 [--replace-all] Upgrade log4j/2.x/ to 2.17.2

Lead-authored-by: --replace-all <rishi.ray@knoldus.com>
Co-authored-by: Rishi Kumar Ray <87641376+RishiKumarRay@users.noreply.github.com>
Signed-off-by: Kent Yao <yao@apache.org>
2022-03-08 19:50:37 +08:00
Kent Yao
abf2026816
[KYUUBI #2045] Preparing v1.6.0-SNAPSHOT
### _Why are the changes needed?_

Preparing v1.6.0-SNAPSHOT with branch-1.5 cut

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2045 from yaooqinn/pv.

Closes #2045

6a506a8f [Kent Yao] Preparing v1.6.0-SNAPSHOT

Authored-by: Kent Yao <yao@apache.org>
Signed-off-by: Kent Yao <yao@apache.org>
2022-03-06 22:21:45 +08:00
SteNicholas
ce8462705f
[KYUUBI #1961] Upgrade hive-service-rpc to 3.1.2
### _Why are the changes needed?_

Upgrade `hive-service-rpc` to 3.1.2.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2031 from SteNicholas/KYUUBI-1961.

Closes #1961

88c29557 [SteNicholas] [KYUUBI #1961] Upgrade hive-service-rpc to 3.1.2

Authored-by: SteNicholas <programgeek@163.com>
Signed-off-by: Kent Yao <yao@apache.org>
2022-03-04 18:41:34 +08:00
Ada Wong
e250c4ae35
[KYUUBI #2000][DEPS] Bump Hadoop 3.3.2
### _Why are the changes needed?_

Hadoop 3.3.2 is out.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #2003 from deadwind4/KYUUBI-2000.

Closes #2000

3b5b3f85 [Ada Wong] [KYUUBI #2000][DEPS] Bump Hadoop 3.3.2

Authored-by: Ada Wong <rsl4@foxmail.com>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-03-03 21:48:25 +08:00
Cheng Pan
7887a47e02
[KYUUBI #1996] Clean up log4j2 conf and enhance surefire plugin conf
### _Why are the changes needed?_

[THRIFT-4805](https://issues.apache.org/jira/browse/THRIFT-4805) has been fixed in thrift 0.13.0, we can remove the workaround of log4j2 configurations because we use thrift 0.16.0 now, the change also removes the following warnings.

```
2022-03-01 23:18:16,530 main ERROR Filters contains invalid attributes "onMatch", "onMismatch"
2022-03-01 23:18:16,543 main ERROR Filters contains invalid attributes "onMatch", "onMismatch"
```

`maven-surefire-plugin` is only used in `kyuubi-hive-jdbc`, we should disable it in other modules.

```
[INFO] --- maven-surefire-plugin:2.22.0:test (default-test)  kyuubi-ctl_2.12 ---
[INFO]
[INFO] -------------------------------------------------------
[INFO]  T E S T S
[INFO] -------------------------------------------------------
2022-03-01 23:18:16,530 main ERROR Filters contains invalid attributes "onMatch", "onMismatch"
2022-03-01 23:18:16,543 main ERROR Filters contains invalid attributes "onMatch", "onMismatch"
[INFO] Running org.apache.kyuubi.ctl.ServiceControlCliSuite
[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.031 s - in org.apache.kyuubi.ctl.ServiceControlCliSuite
[INFO] Running org.apache.kyuubi.ctl.ServiceControlCliArgumentsSuite
[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0 s - in org.apache.kyuubi.ctl.ServiceControlCliArgumentsSuite
[INFO]
[INFO] Results:
[INFO]
[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0
```

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1996 from pan3793/log.

Closes #1996

291441c0 [Cheng Pan] nit
f2c94246 [Cheng Pan] Tune surefire plugin in conf
e1ee6402 [Cheng Pan] Clean up log4j2 conf

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-03-03 12:58:38 +08:00
Kent Yao
d6bbe32a01
[KYUUBI #1981] Remove unused artifacts for common and parent module
### _Why are the changes needed?_

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1981 from yaooqinn/branch-dep.

Closes #1981

07bf0e29 [Kent Yao] codec
96e41e7d [Kent Yao] codec
1da26432 [Kent Yao] guava
6cf0abb3 [Kent Yao] base64 & sha1
3b45ec2a [Kent Yao] base64
5490cfa7 [Kent Yao] http
6f4b48b8 [Kent Yao] n
2a87a4cf [Kent Yao] d
a5ad3ccc [Kent Yao] Refine Deps in common module
24d5299e [Kent Yao] Refine Deps in common module

Authored-by: Kent Yao <yao@apache.org>
Signed-off-by: Kent Yao <yao@apache.org>
2022-03-01 13:35:49 +08:00
Cheng Pan
a3d9ca31d3
[KYUUBI #1974] Support merge small files in multi insert statement
### _Why are the changes needed?_

This PR aims to support auto merge small files in multi insert statement, for example

`FROM VALUES(1) INSERT INTO tmp1 SELECT * INSERT INTO tmp2 SELECT *;`

will generate the following plan, `Union` is the root node instead of `InsertIntoHiveTable`

```
Union
:- InsertIntoHiveTable
:  +- Project
:    +- LocalRelation
+- InsertIntoHiveTable
   +- Project
     +- LocalRelation
```

This PR also fixed the `canInsertRepartitionByExpression`, previous it did not consider the `SubqueryAlias` which may cause inserting error `Repartition`/`Reblance` node and currupt the data distribution, e.g.

`FROM (SELECT * FROM VALUES(1) DOSTRIBUTE BY col1) INSERT INTO tmp1 SELECT * INSERT INTO tmp2 SELECT *;`

```
Union
:- InsertIntoHiveTable
:  +- Project
:     +- SubqueryAlias
:        +- RepartitionByExpression
:           +- Project
:              +- LocalRelation
+- InsertIntoHiveTable
   +- Project
      +- SubqueryAlias
         +- RepartitionByExpression
            +- Project
               +- LocalRelation
```

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1974 from pan3793/ext.

Closes #1974

56cd7734 [Cheng Pan] nit
e0155c27 [Cheng Pan] Support merge small files in multi table insertion

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-02-24 21:10:46 +08:00
ulysses-you
19335334db
[KYUUBI #1948][FOLLOWUP] Remove TFramedTransport in extension-spark-3-1 and extension-spark-3-2
### _Why are the changes needed?_

We have `TFramedTransport` in test of `kyuubi-extension-spark-common` and the `kyuubi-extension-spark-3-1` and `kyuubi-extension-spark-3-2` have already dependent on the test-jar of `kyuubi-extension-spark-common`.

So it's redundant, and we can remove `TFramedTransport` in  `kyuubi-extension-spark-3-1` and `kyuubi-extension-spark-3-2`

### _How was this patch tested?_
Pass CI

Closes #1971 from ulysses-you/KYUUBI-1948-FOLLOWUP.

Closes #1948

43193606 [ulysses-you] remove TFramedTransport in extension spark-3-1 and spark-3-2

Authored-by: ulysses-you <ulyssesyou18@gmail.com>
Signed-off-by: Kent Yao <yao@apache.org>
2022-02-24 11:03:29 +08:00
SteNicholas
770499ca54
[KYUUBI #1948] Upgrade thrift version to 0.16.0
### _Why are the changes needed?_

Upgrade libthrift to 0.16.0 due to [CVE-2020-13949](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-13949) and the coming upstream change of Spark https://github.com/apache/spark/pull/34362

### _What changed in this PR?_

- Upgrade libthrift to 0.16.0

- Shade and relocate `thrift` and `hive-service-rpc` classes in `kyuubi-spark-engine`, it's necessary to avoide conflicting with old thrift libs bundled in Spark binary releases.

- Due to thrift change the method signature, the subclasses those interfaces in Kyuubi also need to modify to pass compile.
We rely on Hive 2.3.9 jars in some components, e.g. `kyuubi-hive-jdbc`, `LocalMetaServer` in `kyuubi-server` test classes.

Some classes in Hive jars compiled against old thrift interfaces which are not compatible with thrift 0.16.0, it causes runtime link error, we found the following classes which breaks the test and copied them with necessary modification to make it work with thrift 0.16.0.

    - `TFramedTransport`
    - `TFilterTransport`
    - `TUGIAssumingTransport`
    - `TUGIContainingTransport`

- Next Steps, I think it's worth to do in separated PRs.

    - Recover the `HiveDelegationTokenProviderSuite`, one approach is use an isolate classloader to load HMS classes and thrift 0.9.3 classes from Maven, this approach can also be used for the planed Zoopkeeper upgrading to help us verficating the compatibility of Zookeeper Server 3.4.x.
    - Rewrite `kyuubi-hive-jdbc` to make it decouple with Hive jars, because there maybe other places which may not work with thrift 0.16.0 but the UTs does not cover.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1953 from SteNicholas/KYUUBI-1948.

Closes #1948

de5d1ea2 [SteNicholas] [KYUUBI #1948] Upgrade thrift version to 0.16.0
898effcd [SteNicholas] [KYUUBI #1948] Upgrade thrift version to 0.16.0
803e270c [SteNicholas] [KYUUBI #1948] Upgrade thrift version to 0.16.0

Authored-by: SteNicholas <programgeek@163.com>
Signed-off-by: Kent Yao <yao@apache.org>
2022-02-23 20:51:59 +08:00
Kent Yao
9b42537164
[KYUUBI #1957] Skip html comments in merge commit test body from PR desc
### _Why are the changes needed?_

Make the `git log` pretty

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1957 from yaooqinn/merge.

Closes #1957

95be6266 [Kent Yao] Skip html comments in merge commit test body from PR desc
dfc8f2f8 [Kent Yao] Skip html comments in merge commit test body from PR desc
8b3eeffe [Kent Yao] Skip html comments in merge commit test body from PR desc

Authored-by: Kent Yao <yao@apache.org>
Signed-off-by: Kent Yao <yao@apache.org>
2022-02-22 14:19:49 +08:00
Kent Yao
f25e5c93b8
[KYUUBI #1949] [INFA] Add homepage for every module in maven central
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
  1. If you add a feature, you can talk about the use case of it.
  2. If you fix a bug, you can clarify why it is a bug.
-->

Take spark as an example.

![image](https://user-images.githubusercontent.com/8326978/154938094-87e53b38-5264-4aca-a7e2-269f9bb3c2d1.png)

[link](https://mvnrepository.com/artifact/org.apache.spark/spark-core_2.13/3.2.1)

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1949 from yaooqinn/url.

Closes #1949

f88c0598 [Kent Yao] [INFA] Add homepage for every module in maven cental
684f588f [Kent Yao] [INFA] Add homepage for every module in maven cental

Authored-by: Kent Yao <yao@apache.org>
Signed-off-by: Kent Yao <yao@apache.org>
2022-02-21 21:09:29 +08:00
ulysses-you
681153036d
[KYUUBI #1536] Add session conf advisor
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
  1. If you add a feature, you can talk about the use case of it.
  2. If you fix a bug, you can clarify why it is a bug.
-->
closes https://github.com/apache/incubator-kyuubi/issues/1536

### _How was this patch tested?_
- [x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1892 from ulysses-you/KYUUBI-1536.

Closes #1536

f0c450a9 [ulysses-you] codecov
35fac4f6 [ulysses-you] fix
f34cfbf4 [ulysses-you] comment
78a54bc1 [ulysses-you] address comment
5cb574ba [ulysses-you] fix test
1033909b [ulysses-you] fix
3c925e56 [ulysses-you] address comment
a74988cd [ulysses-you] style
649f02d0 [ulysses-you] Add session conf advisor
debd3adb [ulysses-you] Add session conf advisor

Authored-by: ulysses-you <ulyssesyou18@gmail.com>
Signed-off-by: ulysses-you <ulyssesyou@apache.org>
2022-02-15 17:48:43 +08:00
Kent Yao
e37e6a22d0
[KYUUBI #1908] Codecov for flink/trino/beeline/jdbc modules
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
  1. If you add a feature, you can talk about the use case of it.
  2. If you fix a bug, you can clarify why it is a bug.
-->

Add missing Codecov settings for flink/trino/beeline/jdbc modules

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1908 from yaooqinn/codecov2.

Closes #1908

89f0b59d [Kent Yao] Codecov for flink/trino/beeline/jdbc modules
f51cc0e8 [Kent Yao] Codecov for flink/trino/beeline/jdbc modules

Authored-by: Kent Yao <yao@apache.org>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-02-14 20:45:07 +08:00
Cheng Pan
68b924513c
[KYUUBI #1811] TPC-DS benchmark expose cli args breakdown and results-dir
### _Why are the changes needed?_

Expose `breakdown` and `results-dir` as cli arg in TPC-DS benchmark tool

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1811 from pan3793/tpcds.

Closes #1811

18637ce7 [Cheng Pan] nit
cc10a7ea [Cheng Pan] style
51e07398 [Cheng Pan] expose results-dir
4bc57995 [Cheng Pan] TPC-DS benchmark expose cli arg breakdown

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: ulysses-you <ulyssesyou@apache.org>
2022-02-11 13:30:37 +08:00
senmiaoliu
0d1502e3d7
[KYUUBI #1880] Fixed: forcedMaxOutputRows extension for join
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
  1. If you add a feature, you can talk about the use case of it.
  2. If you fix a bug, you can clarify why it is a bug.
-->
Fixed #1880

### _How was this patch tested?_
- [x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [x] Add screenshots for manual tests if appropriate

![image](https://user-images.githubusercontent.com/18713676/153140115-ecc1f983-8ac1-40f4-a4a2-ea9275f03674.png)

![image](https://user-images.githubusercontent.com/18713676/153140075-f86e01a0-3824-419d-b82d-239b14c77092.png)

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1881 from lsm1/fix/fore_maxOutputRows.

Closes #1880

8bc414f2 [senmiaoliu] fix format
c9308f5c [senmiaoliu] fix join

Authored-by: senmiaoliu <senmiaoliu@trip.com>
Signed-off-by: ulysses-you <ulyssesyou@apache.org>
2022-02-11 10:17:22 +08:00
Cheng Pan
33eda2159f
[KYUUBI #1884] Fix compile SQL measurement
### _Why are the changes needed?_

The previous measurement of parsing and analysis does not make sense because `Dataset` calls `queryExecution.assertAnalyzed()` in the constructor.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1884 from pan3793/measure.

Closes #1884

8da93874 [Cheng Pan] Fix compile SQL measurement

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: ulysses-you <ulyssesyou@apache.org>
2022-02-10 09:43:52 +08:00
Paul Lin
0233fbe5ab
[KYUUBI #1878] Fix typo in log4j2-test.properties
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
  1. If you add a feature, you can talk about the use case of it.
  2. If you fix a bug, you can clarify why it is a bug.
-->

Fix typo.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1879 from link3280/bug/KYUUBI-1878.

Closes #1878

ed1f3268 [Paul Lin] [KYUUBI #1878] Fix typo in log4j2-test.properties

Authored-by: Paul Lin <paullin3280@gmail.com>
Signed-off-by: ulysses-you <ulyssesyou@apache.org>
2022-02-09 11:47:51 +08:00
ulysses-you
73c84d42e7
[KYUUBI #1868] Upgrate netty from 4.1.68 to 4.1.73
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
  1. If you add a feature, you can talk about the use case of it.
  2. If you fix a bug, you can clarify why it is a bug.
-->
close https://github.com/apache/incubator-kyuubi/issues/1868

### _How was this patch tested?_
Pass CI

Closes #1869 from ulysses-you/netty.

Closes #1868

c197d0e3 [ulysses-you] Upgrate netty from 4.1.68 to 4.1.73

Authored-by: ulysses-you <ulyssesyou18@gmail.com>
Signed-off-by: ulysses-you <ulyssesyou@apache.org>
2022-02-09 10:57:46 +08:00
Kent Yao
08fc087e25
[KYUUBI #1875] Upgrade codahale.metrics.version to 4.2.8 and its deps
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
  1. If you add a feature, you can talk about the use case of it.
  2. If you fix a bug, you can clarify why it is a bug.
-->

Upgrade codahale.metrics.version to 4.2.8, jackson to 2.13.1 abd slf4j to 1.7.35
### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1875 from yaooqinn/md.

Closes #1875

12a21729 [Kent Yao] Upgrade codahale.metrics.version to 4.2.8

Authored-by: Kent Yao <yao@apache.org>
Signed-off-by: ulysses-you <ulyssesyou@apache.org>
2022-02-09 09:28:20 +08:00
Cheng Pan
839c5c5bf4
[KYUUBI #1861] Migrate bind-api and activation-api from javax to jakarta
### _Why are the changes needed?_

The Java world is migrating JavaEE components from `javax` to `jakarta`, we should follow it.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1861 from pan3793/jaxb.

Closes #1861

3563b773 [Cheng Pan] Migrate bind-api activation-api to jakarta

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-02-04 14:59:28 +08:00
Cheng Pan
b2bad04d75 [KYUUBI #1769][FOLLOWUP] Exclude log4j 12 deps from spark-hive and fix detect deps change workflow
### _Why are the changes needed?_

The previous PR did not handle log4j 1.2 deps of `spark-hive`, and the current detect deps change workflow has the dirty cache issue, this PR also fix it.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1856 from pan3793/log4j2.

Closes #1769

2785acf4 [Cheng Pan] nit
58affcb5 [Cheng Pan] update workflow
301acb6f [Cheng Pan] update check deps script
7611c7e0 [Cheng Pan] revert exclusion
239e7cc4 [Cheng Pan] Remove duplicated scalatest
e143fecc [Cheng Pan] dependencyList
a7254771 [Cheng Pan] [KYUUBI #1769][FOLLOWUP] Exclude log4j 12 deps from test deps

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Fei Wang <fwang12@ebay.com>
2022-02-01 23:59:17 +08:00
Paul Lin
8b389f27fd
[KYUUBI #1858] Rename test log4j2 properties to log4j2-test.properties
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
  1. If you add a feature, you can talk about the use case of it.
  2. If you fix a bug, you can clarify why it is a bug.
-->

Avoid test log4j2 configurations overtaken by the ones in 3rd party dependencies.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1860 from link3280/bug/KYUUBI-1858.

Closes #1858

614e7937 [Paul Lin] [KYUUBI #1858] Update log2j configuration path in pom.xml
71c95613 [Paul Lin] [KYUUBI #1858] Rename test log4j2 properties to log4j2-test.properties

Authored-by: Paul Lin <paullin3280@gmail.com>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-02-01 01:22:58 +08:00
SteNicholas
463f851351
[KYUUBI #1850] Bump Prometheus 0.14.1
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
Bump Prometheus 0.14.1.

There are some breaking changes, please go to https://github.com/prometheus/client_java/releases to learn details.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [x] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1857 from SteNicholas/KYUUBI-1850.

Closes #1850

41c6f682 [SteNicholas] [KYUUBI #1850] Bump Prometheus 0.14.1

Authored-by: SteNicholas <programgeek@163.com>
Signed-off-by: Cheng Pan <chengpan@apache.org>
2022-01-31 13:33:27 +08:00
Cheng Pan
3323bae886 [KYUUBI #1855] Suppress logging to console in scalatest
### _Why are the changes needed?_

This change recovers the previous behavior, writing logs to `target/unit-tests.log` instead of print log to console in scalatest.

### _How was this patch tested?_
- [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1855 from pan3793/debug.

Closes #1855

a6ea4e46 [Cheng Pan] Suppress logging to console in scalatest

Authored-by: Cheng Pan <chengpan@apache.org>
Signed-off-by: Fei Wang <fwang12@ebay.com>
2022-01-30 14:18:23 +08:00
Fei Wang
885ace06c8 [KYUUBI #1769][FOLLOWUP] Some cleanups for log4j properties
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
  1. If you add a feature, you can talk about the use case of it.
  2. If you fix a bug, you can clarify why it is a bug.
-->

This is a followup of #1769. Cleanup the log4j properties files and using log4j2.properties for UT.

### _How was this patch tested?_

Passed UT.

Closes #1842 from turboFei/remove_log4j1.

Closes #1769

b6757555 [Fei Wang] unused change
365fbec7 [Fei Wang] revert license
14c64ec9 [Fei Wang] exclude log4j 1.2.17 in slf4j-log4j12
034b04db [Fei Wang] recover jcl-over-slf4j and slf4j-api for k8s it
2beae75e [Fei Wang] remove log4j 1.2.17
b00f07b5 [Fei Wang] remove from license
e55fd2ec [Fei Wang] remove unused dependencies
ab86f023 [Fei Wang] [KYUUBI #1769][FOLLOWUP] Some cleanups for log4j properties

Authored-by: Fei Wang <fwang12@ebay.com>
Signed-off-by: Fei Wang <fwang12@ebay.com>
2022-01-28 00:58:25 +08:00
Fei Wang
53d59a02bf [KYUUBI #1769] [BUILD] Migrate from log4j1 to log4j2
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
  1. If you add a feature, you can talk about the use case of it.
  2. If you fix a bug, you can clarify why it is a bug.
-->
This patch proposes to migrate from log4j1 to log4j2 in Kyuubi.
Refer the spark patch: https://github.com/apache/spark/pull/34895

### Does this PR introduce any user-facing change?
Yes. Users may need to rewrite their log4j properties file for log4j2. As of version 2.4, log4j now supports configuration via properties files. Note that the property syntax is not the same as the syntax used in log4j 1, but during the migration I found the syntax is pretty close so the migration should be straightforward.

### _How was this patch tested?_
Passed all existing tests.

Closes #1769 from turboFei/log4j2.

Closes #1769

8613779c [Fei Wang] remove log4j dependencies from spark-sql-engine
b2fe6dba [Fei Wang] Use String to present default log level
762e2d03 [Fei Wang] only remove org.apache.logging.log4j:log4j-slf4j-impl
8a912086 [Fei Wang] remove dependencies from spark-sql-engine
7e3a4980 [Fei Wang] address commments
051f49f5 [Fei Wang] address comments
85316a0b [Fei Wang] Keep compatible with log4j12
01d1a84e [Fei Wang] for log4j1
b9e17e1b [Fei Wang] refactor
e24391ed [Fei Wang] revert log count
38803002 [Fei Wang] add log4j2.properties.template
4f0b22fc [Fei Wang] save
7ce84119 [Fei Wang] modify log level
1ea5ca53 [Fei Wang] add log4j to engine
c4a86d4d [Fei Wang] use AbstractFilter
27b08b6a [Fei Wang] remove more
8cc15ae7 [Fei Wang] reformat
c13ec29e [Fei Wang] save temporarily
33a38e2e [Fei Wang] exclude log4j12 from spark-sql
9129a64a [Fei Wang] refactor
5362b43d [Fei Wang] make it run at first
7f27f519 [Fei Wang] more
56f4f1ff [Fei Wang] fix logging
a74b6d37 [Fei Wang] start appender
dea964aa [Fei Wang] fix build erorr at first
e20b7500 [Fei Wang] address comments
2ec02b4d [Fei Wang] fix LogDivertAppender
dded1290 [Fei Wang] more
c63e0008 [Fei Wang] add log4j2.properties

Authored-by: Fei Wang <fwang12@ebay.com>
Signed-off-by: Fei Wang <fwang12@ebay.com>
2022-01-26 10:53:16 +08:00
odone
5ea0964e26
[KYUUBI #1832] Fixed: forcedMaxOutputRows extension for subquery
<!--
Thanks for sending a pull request!

Here are some tips for you:
  1. If this is your first time, please read our contributor guidelines: https://kyuubi.readthedocs.io/en/latest/community/contributions.html
  2. If the PR is related to an issue in https://github.com/apache/incubator-kyuubi/issues, add '[KYUUBI #XXXX]' in your PR title, e.g., '[KYUUBI #XXXX] Your PR title ...'.
  3. If the PR is unfinished, add '[WIP]' in your PR title, e.g., '[WIP][KYUUBI #XXXX] Your PR title ...'.
-->

### _Why are the changes needed?_
<!--
Please clarify why the changes are needed. For instance,
  1. If you add a feature, you can talk about the use case of it.
  2. If you fix a bug, you can clarify why it is a bug.
-->
Fixed #1832

### _How was this patch tested?_
- [x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

- [ ] Add screenshots for manual tests if appropriate

- [ ] [Run test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request

Closes #1833 from iodone/1832-bug.

Closes #1832

52769746 [odone] [KYUUBI #1832] Added: Add some test case
61d733dc [odone] [KYUUBI #1832] fixed: spotless
d8ee657a [odone] [KYUUBI #1832] fixed: forcedMaxOutputRows extension for subquery
efd87a75 [odone] [KYUUBI #1832] fixed: forcedMaxOutputRows extension for subquery

Authored-by: odone <odone.zhang@gmail.com>
Signed-off-by: ulysses-you <ulyssesyou@apache.org>
2022-01-26 09:32:54 +08:00