You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2022/02/13 02:43:08 UTC
[GitHub] [incubator-doris] lihuigang opened a new pull request #8036: Hive Bitmap udf
lihuigang opened a new pull request #8036:
URL: https://github.com/apache/incubator-doris/pull/8036
# Proposed changes
Hive Bitmap UDF provides UDFs for generating bitmap and bitmap operations in hive tables. The bitmap in Hive is exactly the same as the Doris bitmap. The bitmap in Hive can be imported into doris through spark bitmap load.
Issue Number: close #xxx
## Problem Summary:
Describe the overview of changes.
## Checklist(Required)
1. Does it affect the original behavior: (No)
2. Has unit tests been added: (No Need)
3. Has document been added or modified: (Yes)
4. Does it need to update dependencies: (Yes)
5. Are there any changes that cannot be rolled back: (No)
## Further comments
If this is a relatively large or complex change, kick off the discussion at [dev@doris.apache.org](mailto:dev@doris.apache.org) by explaining why you chose the solution you did and what alternatives you considered, etc...
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [incubator-doris] morningman commented on a change in pull request #8036: add Hive Bitmap UDFs
Posted by GitBox <gi...@apache.org>.
morningman commented on a change in pull request #8036:
URL: https://github.com/apache/incubator-doris/pull/8036#discussion_r805305092
##########
File path: docs/zh-CN/extending-doris/hive-bitmap-udf.md
##########
@@ -0,0 +1,102 @@
+---
+{
+ "title": "Hive Bitmap UDF",
+ "language": "zh-CN"
+}
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+# Hive UDF
+
+ Hive Bitmap UDF 提供了在 hive 表中生成 bitmap 、bitmap 运算等 UDF,Hive 中的 bitmap 与 Doris bitmap 完全一致 ,Hive 中的 bitmap 可以通过 spark bitmap load 导入 doris
+
+ 主要目的:
+ 1. 减少数据导入 doris 时间 , 除去了构建字典、bitmap 预聚合等流程;
+ 2. 节省 hive 存储 ,使用 bitmap 对数据压缩 ,减少了存储成本;
+ 3. 提供在 hive 中 bitmap 的灵活运算 ,比如:用户留存、流失等人群 ,计算后的 bitmap 也可以直接导入 doris;
+
+## 使用方法
+
+### 在 Hive 中创建 Bitmap 类型表
+
+```sql
+
+-- 例子:创建 Hive Bitmap 表
+CREATE TABLE IF NOT EXISTS `hive_bitmap_table`(
+ `k1` int COMMENT '',
+ `k2` String COMMENT '',
+ `k3` String COMMENT '',
+ `uuid` binary COMMENT 'bitmap'
+) comment 'comment'
+
+-- 例子:创建普通 Hive 表
+CREATE TABLE IF NOT EXISTS `hive_table`(
+ `k1` int COMMENT '',
+ `k2` String COMMENT '',
+ `k3` String COMMENT '',
+ `uuid` int COMMENT ''
+) comment 'comment'
+```
+
+### UDF 使用:
+
Review comment:
1. Please add english document
2. Are these commands executed in hive, or in doris?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [incubator-doris] github-actions[bot] commented on pull request #8036: add Hive Bitmap UDFs
Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #8036:
URL: https://github.com/apache/incubator-doris/pull/8036#issuecomment-1041101197
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [incubator-doris] morningman commented on a change in pull request #8036: add Hive Bitmap UDFs
Posted by GitBox <gi...@apache.org>.
morningman commented on a change in pull request #8036:
URL: https://github.com/apache/incubator-doris/pull/8036#discussion_r805305092
##########
File path: docs/zh-CN/extending-doris/hive-bitmap-udf.md
##########
@@ -0,0 +1,102 @@
+---
+{
+ "title": "Hive Bitmap UDF",
+ "language": "zh-CN"
+}
+---
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+# Hive UDF
+
+ Hive Bitmap UDF 提供了在 hive 表中生成 bitmap 、bitmap 运算等 UDF,Hive 中的 bitmap 与 Doris bitmap 完全一致 ,Hive 中的 bitmap 可以通过 spark bitmap load 导入 doris
+
+ 主要目的:
+ 1. 减少数据导入 doris 时间 , 除去了构建字典、bitmap 预聚合等流程;
+ 2. 节省 hive 存储 ,使用 bitmap 对数据压缩 ,减少了存储成本;
+ 3. 提供在 hive 中 bitmap 的灵活运算 ,比如:用户留存、流失等人群 ,计算后的 bitmap 也可以直接导入 doris;
+
+## 使用方法
+
+### 在 Hive 中创建 Bitmap 类型表
+
+```sql
+
+-- 例子:创建 Hive Bitmap 表
+CREATE TABLE IF NOT EXISTS `hive_bitmap_table`(
+ `k1` int COMMENT '',
+ `k2` String COMMENT '',
+ `k3` String COMMENT '',
+ `uuid` binary COMMENT 'bitmap'
+) comment 'comment'
+
+-- 例子:创建普通 Hive 表
+CREATE TABLE IF NOT EXISTS `hive_table`(
+ `k1` int COMMENT '',
+ `k2` String COMMENT '',
+ `k3` String COMMENT '',
+ `uuid` int COMMENT ''
+) comment 'comment'
+```
+
+### UDF 使用:
+
Review comment:
1. Please add english document
2. Are these commands executed in hive, or in doris?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [incubator-doris] morningman merged pull request #8036: [feature](spark-load) add Hive Bitmap UDFs
Posted by GitBox <gi...@apache.org>.
morningman merged pull request #8036:
URL: https://github.com/apache/incubator-doris/pull/8036
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org