Coder Social home page Coder Social logo

boostkit-bigdata's People

Contributors

anllick avatar bryanwongsz avatar chenyidao avatar congzhicai avatar fengyun2066 avatar followyourheartanddonothesitate avatar fomist7 avatar gitzhangjingfang avatar gravitys169 avatar guojunfei399 avatar helloxteen avatar hwlsh3535 avatar jiaotongzou avatar jutao-liu avatar lius511 avatar lizheng920625 avatar luodan000 avatar rebecca-liu66 avatar reflectt6 avatar ruanrunxue avatar sipeizhou avatar ssuiyi avatar tedliucas avatar tiantao202212 avatar tushengxia avatar wcg881 avatar wenxuanguan avatar wyy566 avatar xulilililili avatar yang-haitao avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

boostkit-bigdata's Issues

OmniData hive: Product overflow check

【问题现象】(必选)
整数运算前应进行合法性校验确保不溢出
【问题代码片段】(安全类问题必选,其他问题可选;保留文本非截图)
omnidata/omnidata-hive-connector/connector/src/main/java/org/apache/hadoop/hive/ql/omnidata/decode/PageDecoding.java
片段:299行sliceInput.readBytes(Slices.wrappedIntArray(offsets), SIZE_OF_INT, positionCount * SIZE_OF_INT);
应该避免溢出
PS:
1.代码片段保存文本信息,以便后续可正确导出/查阅
【修改建议】(可选)
Math.multiplyExact(num1, num2)

OmniData Hive: Null Pointer reference

【问题描述】(必选)
访问一个为null的对象时,会导致空引用问题,代码中抛出NullPointerException。

【修改建议】(可选)
该类问题应该通过预检查的方式进行消解,而不是通过try...catch 机制处理NullPointerException 。
【问题代码片段】(安全类问题必选,其他问题可选;保留文本非截图)
代码路径:
omnidata/omnidata-hive-connector/connector/src/main/java/org/apache/hadoop/hive/ql/omnidata/physical/NdpPlanChecker.java
片段:
109行:LOG.info("Table [{}] failed to push down, since PartitionDesc is null",
110行: tableScanOp.getConf().getAlias());
当tableScanOp.getConf()为null,会发生空指针异常
PS:
1.代码片段保存文本信息,以便后续可正确导出/查阅

OmniOperator: Spark window does not support lieteral expression

子查询中含有常量表达式作为投影列,然后在外层作为窗口函数的分组列,转化为列引用失败出错了

SELECT
statis_cycle_sign, name, dept, salary, ROW_NUMBER() OVER (PARTITION BY statis_cycle_sign, name, dept ORDER BY salary) AS rank
FROM
( SELECT 'pt_today' AS statis_cycle_sign, name, dept, salary, age from employees) ;

OmniData Spark: InputStream need be closed.

【问题描述】(必选)
进行IO类操作时,必须在try-with-resource或finally里关闭资源。

【修改建议】(可选)
添加try-catch-finally,并在finally中关闭inpustream
【问题代码片段】(安全类问题必选,其他问题可选;保留文本非截图)
代码路径:
omnidata\omnidata-spark-connector\connector\src\main\scala\org\apache\spark\sql\execution\ndp\NdpPushDown.scala
片段:
447行:val inputStream = this.getClass.getResourceAsStream("/"+sourceName),
inputStream没有被关闭,可能出现安全问题
PS:
1.代码片段保存文本信息,以便后续可正确导出/查阅

OmniOperator: Spark ORC Unknown Type Error

Issue: Orc Type Error
image

ORC: TypeKind::Short -> SmallInt -> Omni:Int

OrcColumnarBatchJniReader.cpp, OrcColumnarBgatchJniReader.java needs support for Short type

  1. create table and insert data
    create table if not exists test_smallint(id smallint);
    insert into test_smallint select 1;
  2. running sql:
    select * from test_smallint;
    image

OmniData hive: io need be closed in finally.

【问题现象】(必选)
进行IO类操作时,必须在try-with-resource或finally里关闭资源
【问题代码片段】(安全类问题必选,其他问题可选;保留文本非截图)
omnidata/omnidata-hive-connector/connector/src/main/java/org/apache/hadoop/hive/ql/omnidata/reader/OmniDataAdapter.java
片段:161行dataReader.close(); 应该在finally里关闭资源
PS:
1.代码片段保存文本信息,以便后续可正确导出/查阅
【修改建议】(可选)
在finally中关闭资源dataReader.close();

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.