From issues-return-198025-apmail-hive-issues-archive=hive.apache.org@hive.apache.org Tue Aug 25 08:27:06 2020 Return-Path: X-Original-To: apmail-hive-issues-archive@locus.apache.org Delivered-To: apmail-hive-issues-archive@locus.apache.org Received: from mailroute1-lw-us.apache.org (mailroute1-lw-us.apache.org [207.244.88.153]) by minotaur.apache.org (Postfix) with ESMTP id 3787619891 for ; Tue, 25 Aug 2020 08:27:06 +0000 (UTC) Received: from mail.apache.org (localhost [127.0.0.1]) by mailroute1-lw-us.apache.org (ASF Mail Server at mailroute1-lw-us.apache.org) with SMTP id DAC6B124457 for ; Tue, 25 Aug 2020 08:27:04 +0000 (UTC) Received: (qmail 85877 invoked by uid 500); 25 Aug 2020 08:27:02 -0000 Delivered-To: apmail-hive-issues-archive@hive.apache.org Received: (qmail 85782 invoked by uid 500); 25 Aug 2020 08:27:02 -0000 Mailing-List: contact issues-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@hive.apache.org Delivered-To: mailing list issues@hive.apache.org Received: (qmail 85701 invoked by uid 99); 25 Aug 2020 08:27:02 -0000 Received: from mailrelay1-us-west.apache.org (HELO mailrelay1-us-west.apache.org) (209.188.14.139) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 25 Aug 2020 08:27:02 +0000 Received: from jira-he-de.apache.org (static.172.67.40.188.clients.your-server.de [188.40.67.172]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 5BF8845B67 for ; Tue, 25 Aug 2020 08:27:01 +0000 (UTC) Received: from jira-he-de.apache.org (localhost.localdomain [127.0.0.1]) by jira-he-de.apache.org (ASF Mail Server at jira-he-de.apache.org) with ESMTP id 2A6097806CF for ; Tue, 25 Aug 2020 08:27:00 +0000 (UTC) Date: Tue, 25 Aug 2020 08:27:00 +0000 (UTC) From: "ASF GitHub Bot (Jira)" To: issues@hive.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Work logged] (HIVE-24065) Bloom filters can be cached after deserialization in VectorInBloomFilterColDynamicValue MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/HIVE-24065?focusedWorklogId=3D= 474201&page=3Dcom.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpa= nel#worklog-474201 ] ASF GitHub Bot logged work on HIVE-24065: ----------------------------------------- Author: ASF GitHub Bot Created on: 25/Aug/20 08:26 Start Date: 25/Aug/20 08:26 Worklog Time Spent: 10m=20 Work Description: abstractdog commented on a change in pull request #= 1423: URL: https://github.com/apache/hive/pull/1423#discussion_r476270406 ########## File path: ql/src/java/org/apache/hadoop/hive/ql/exec/vector/expressions/Ve= ctorInBloomFilterColDynamicValue.java ########## @@ -100,26 +103,39 @@ public void init(Configuration conf) { default: throw new IllegalStateException("Unsupported type " + colVectorType)= ; } + + String queryId =3D HiveConf.getVar(conf, HiveConf.ConfVars.HIVEQUERYID= ); + runtimeCache =3D ObjectCacheFactory.getCache(conf, queryId, false, tru= e); } =20 - private void initValue() { - InputStream in =3D null; + private void initValue() { try { - Object val =3D bloomFilterDynamicValue.getValue(); - if (val !=3D null) { - BinaryObjectInspector boi =3D (BinaryObjectInspector) bloomFilterD= ynamicValue.getObjectInspector(); - byte[] bytes =3D boi.getPrimitiveJavaObject(val); - in =3D new NonSyncByteArrayInputStream(bytes); - bloomFilter =3D BloomKFilter.deserialize(in); - } else { - bloomFilter =3D null; - } - initialized =3D true; - } catch (Exception err) { - throw new RuntimeException(err); - } finally { - IOUtils.closeStream(in); Review comment: good catch, I think it's needed, or at least I removed it accidental= ly ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: users@infra.apache.org Issue Time Tracking ------------------- Worklog Id: (was: 474201) Time Spent: 50m (was: 40m) > Bloom filters can be cached after deserialization in VectorInBloomFilterC= olDynamicValue > -------------------------------------------------------------------------= -------------- > > Key: HIVE-24065 > URL: https://issues.apache.org/jira/browse/HIVE-24065 > Project: Hive > Issue Type: Improvement > Reporter: L=C3=A1szl=C3=B3 Bodor > Assignee: L=C3=A1szl=C3=B3 Bodor > Priority: Major > Labels: pull-request-available > Attachments: image-2020-08-05-10-05-25-080.png > > Time Spent: 50m > Remaining Estimate: 0h > > Same bloom filter is loaded multiple times across tasks. It would be good= to check if we can optimise this, to avoid deserializing. -- This message was sent by Atlassian Jira (v8.3.4#803005)