You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kylin.apache.org by xx...@apache.org on 2023/03/02 08:56:20 UTC
[kylin] branch doc5.0 updated (c62dbf3fc8 -> 968a9ca446)
This is an automated email from the ASF dual-hosted git repository.
xxyu pushed a change to branch doc5.0
in repository https://gitbox.apache.org/repos/asf/kylin.git
from c62dbf3fc8 Update community activity page
new 63fec2a84a KYLIN-5447 add logical view desc
new 968a9ca446 KYLIN-5454 update async query api
The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
website/docs/datasource/logical_view.md | 53 +++++++++++++++++++++++++++++++++
website/docs/restapi/async_query_api.md | 7 +++--
website/sidebars.js | 4 +++
3 files changed, 61 insertions(+), 3 deletions(-)
create mode 100644 website/docs/datasource/logical_view.md
[kylin] 02/02: KYLIN-5454 update async query api
Posted by xx...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
xxyu pushed a commit to branch doc5.0
in repository https://gitbox.apache.org/repos/asf/kylin.git
commit 968a9ca4466ff2eb7e72a0b72e5c1626672fba23
Author: DorrisRuixuanZhang <do...@hotmail.com>
AuthorDate: Tue Feb 28 17:37:52 2023 +0800
KYLIN-5454 update async query api
---
website/docs/restapi/async_query_api.md | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/website/docs/restapi/async_query_api.md b/website/docs/restapi/async_query_api.md
index e297b20e32..a7c394e08f 100644
--- a/website/docs/restapi/async_query_api.md
+++ b/website/docs/restapi/async_query_api.md
@@ -11,7 +11,7 @@ keywords:
- async query api
draft: false
last_update:
- date: 08/12/2022
+ date: 02/28/2023
---
> Reminders:
@@ -21,6 +21,7 @@ last_update:
> 3. In this chapter, all get requests and delete by ID request are forward compatible, that is, if the project parameter is not transferred to the URL, the request can also be successful if the project parameter is transferred to the request body.
> 4. Due to the requirements of the parquet format, the naming of the column can not contain characters such as ",; {} () \\ n\\ t =", so you need to display the definition alias in the SQL query, and the alias does not contain these special characters.
> 5. The earlier versions of hive do not support reading the parquet date type field, so you can replace the original table data type with timestamp, or upgrade hive to the versions after 1.2 .
+> 6. In order to solve performance problem, we move the `include_header` parameter to Submit Async Query API, the `include_header` parameter in Download Query Result API doesn't work now.
@@ -40,10 +41,11 @@ last_update:
- `limit` - `optional` `int `, limit on the quantity of query result
- `project` - `required` `string`, project name
- `format` - `optional` `string`,file format, the default value is "csv", other optional values are "json", "xlsx", "parquet"
- > Note: When the file format is "xlsx" or "json", specifying the separator separator is not supported. When the file format is "parquet", it is currently not supported to download the result file through the [Download Query Result](#Download-Query-Result) API, and can only be obtained directly from HDFS.
+ > Note: When the file format is "xlsx" or "json", specifying the separator separator is not supported. When the file format is "parquet", it is currently not supported to download the result file through the [Download Query Result](#Download-Query-Result) API, and can only be obtained directly from HDFS. File format "xlsx" may cause performance issue, therefore is not recommended.
- `encode` - `optional` `string`,file encoding, the default value is "utf-8", other optional values are "gbk"
- `file_name` - `optional` `string`,file name, Chinese is not supported temporarily, the default value is "result"
- `spark_queue` - `optional` `string`, the cluster queue specified, the default value is "default". It will take effect after enabling `kylin.query.unique-async-query-yarn-queue-enabled`
+ - `include_header` - `optional` `boolean`, whether the result includes header, the default value is `false`
- Curl Request Example
@@ -225,7 +227,6 @@ last_update:
- URL Parameters
- `query_id` - `required` `string`, Query ID of the Async Query
- - `include_header` - `optional` `boolean`, result include header, default is false
- `project` `required` `string`, project name
- HTTP Header
[kylin] 01/02: KYLIN-5447 add logical view desc
Posted by xx...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
xxyu pushed a commit to branch doc5.0
in repository https://gitbox.apache.org/repos/asf/kylin.git
commit 63fec2a84a4abe265227adf4c73f883456a73ae3
Author: DorrisRuixuanZhang <do...@hotmail.com>
AuthorDate: Tue Feb 28 17:37:12 2023 +0800
KYLIN-5447 add logical view desc
---
website/docs/datasource/logical_view.md | 53 +++++++++++++++++++++++++++++++++
website/sidebars.js | 4 +++
2 files changed, 57 insertions(+)
diff --git a/website/docs/datasource/logical_view.md b/website/docs/datasource/logical_view.md
new file mode 100644
index 0000000000..871e3f3698
--- /dev/null
+++ b/website/docs/datasource/logical_view.md
@@ -0,0 +1,53 @@
+---
+title: Logical View
+language: en
+sidebar_label: Logical View
+pagination_label: Logical View
+toc_min_heading_level: 2
+toc_max_heading_level: 6
+pagination_prev: null
+pagination_next: null
+keywords:
+ - logical view
+draft: false
+last_update:
+ date: 02/28/2023
+---
+
+## Logical View
+- Logical view is a special view maintained only in KYLIN rather than a real view in hive. Once created, you can use it like a normal Hive view.
+- Logical view feature is turned off by default, you can set `kylin.source.ddl.logical-view.enabled=true` to turn this feature on.
+- All logical views are in the same database, you can set the database name by the following parameters, be careful not to have the same name as the normal Hive database:
+ - `kylin.source.ddl.logical-view.database=KYLIN_LOGICAL_VIEW`
+
+### Main operation flow
+1. Log in to KYLIN, and the login account must be:
+- System admin.
+- Have the Administrator or Project Administrator role for the target project.
+- User has Management Role.
+
+2. Click Data Assets - > Logical View to go to the main page of the logical view, you can enter SQL statements in the text box, and there are three tabs which can respectively manage the logical view tables, load the data source and display the syntax rules.
+
+3. Enter the `Create Logical View as...` statement in the SQL text box to create the logical view, noting that the database name is not required.
+4. After the view is created, you need to load the source table for Modeling to use. Since the logical view is newly created, you need to click "Refresh Now" first, then find the newly created logical view and then complete the loading.
+
+
+### Delete logical view
+1. On the main page of the logical view, you can enter SQL statement on the left: `DROP LOGICAL VIEW logical_view_db.your_logical_view;` to delete the logical view. Pay attention that the database name is needed.
+
+
+### View/Edit Logical View
+1. In the main interface of the logical view, click the 'Logical View Chart' (L) tab, you can see all the created logical views, those of current project will be pinned to the top, and those belonging to other projects will be grey out.
+2. Click the pencil icon next to the view to enter view/edit page.
+
+3. On this page, you can view the create view statement.
+4. To edit the table definition, click the 'create - > replace' icon
+
+5. You can see that `Create Logical View` in the edit box is replaced with `Replace Logical View`, and then you can modify the previous create table statement. In the following example, the condition of `where 1 = 1` is added.
+
+6. Click Save to complete the editing of the logical view.
+
+### Precautions
+1. Logical views must be created under the same virtual database. (The database name can be determined through the parameter above.)
+2. In order to prevent users from overriding existing project permissions with the help of logical views, the source table used in logical views needs to be loaded into the data source, and users can only load/edit logical views created under the same project.
+3. Logical views currently do not support RDBMS JDBC data sources. It only support Hive data sources.
\ No newline at end of file
diff --git a/website/sidebars.js b/website/sidebars.js
index c4f1120e6f..ee40ac34bf 100644
--- a/website/sidebars.js
+++ b/website/sidebars.js
@@ -457,6 +457,10 @@ const sidebars = {
type: 'doc',
id: 'datasource/data_sampling'
},
+ {
+ type: 'doc',
+ id: 'datasource/logical_view'
+ },
],
},
{