From notifications-return-155230-archive-asf-public=cust-asf.ponee.io@asterixdb.apache.org Tue Apr 21 12:48:45 2020 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id A3D1418065D for ; Tue, 21 Apr 2020 14:48:44 +0200 (CEST) Received: (qmail 91143 invoked by uid 500); 21 Apr 2020 12:48:44 -0000 Mailing-List: contact notifications-help@asterixdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@asterixdb.apache.org Delivered-To: mailing list notifications@asterixdb.apache.org Received: (qmail 91127 invoked by uid 99); 21 Apr 2020 12:48:44 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 21 Apr 2020 12:48:44 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 8DB06C1BEB for ; Tue, 21 Apr 2020 12:48:43 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -112.189 X-Spam-Level: X-Spam-Status: No, score=-112.189 tagged_above=-999 required=6.31 tests=[ENV_AND_HDR_SPF_MATCH=-0.5, KAM_ASCII_DIVIDERS=0.8, KAM_DMARC_STATUS=0.01, RCVD_IN_DNSWL_HI=-5, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001, USER_IN_DEF_SPF_WL=-7.5, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-ec2-va.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id UQU6hINWvFCG for ; Tue, 21 Apr 2020 12:48:39 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=207.244.88.153; helo=mail.apache.org; envelope-from=jira@apache.org; receiver= Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx1-ec2-va.apache.org (ASF Mail Server at mx1-ec2-va.apache.org) with SMTP id 361C0BB9A7 for ; Tue, 21 Apr 2020 12:41:02 +0000 (UTC) Received: (qmail 74756 invoked by uid 99); 21 Apr 2020 12:41:01 -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, 21 Apr 2020 12:41:01 +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 9D13BE30C8 for ; Tue, 21 Apr 2020 12:41:00 +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 1BE8078043D for ; Tue, 21 Apr 2020 12:41:00 +0000 (UTC) Date: Tue, 21 Apr 2020 12:41:00 +0000 (UTC) From: "Hussain Towaileb (Jira)" To: notifications@asterixdb.incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Resolved] (ASTERIXDB-2717) Querying external dataset fails when further data read is needed before decoding 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/ASTERIXDB-2717?page=3Dcom.atla= ssian.jira.plugin.system.issuetabpanels:all-tabpanel ] Hussain Towaileb resolved ASTERIXDB-2717. ----------------------------------------- Resolution: Fixed Fix reference: [https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/5724] > Querying external dataset fails when further data read is needed before d= ecoding > -------------------------------------------------------------------------= ------- > > Key: ASTERIXDB-2717 > URL: https://issues.apache.org/jira/browse/ASTERIXDB-2717 > Project: Apache AsterixDB > Issue Type: Bug > Components: EXT - External data > Affects Versions: 0.9.5 > Reporter: Hussain Towaileb > Assignee: Hussain Towaileb > Priority: Major > Fix For: 0.9.5 > > > In some scenarios, some characters are represented by multiple bytes, and= the bytes are partially read (rest of the bytes is in the next read). In t= his case, the decoder will fail to decode, and will wait for the next read = to have all the bytes together then try to decode it. > =C2=A0 > In the above scenario, the ByteBuffer limit is not being reset before rea= ding again, which could lead to the position being greater than the limit a= nd throwing an exception. > =C2=A0 > For example: > =C2=A0 > {code:java} > org.apache.hyracks.api.exceptions.HyracksDataException: java.lang.Illegal= ArgumentException: newPosition > limit: (4096 > 1048) > at org.apache.hyracks.api.exceptions.HyracksDataException.create(Hyracks= DataException.java:51) ~[hyracks-api.jar:6.6.0-11077] > at org.apache.asterix.external.dataflow.RecordDataFlowController.start(R= ecordDataFlowController.java:59) ~[asterix-external-data.jar:6.6.0-11077] > at org.apache.asterix.external.dataset.adapter.GenericAdapter.start(Gene= ricAdapter.java:36) ~[asterix-external-data.jar:6.6.0-11077] > at org.apache.asterix.external.operators.ExternalScanOperatorDescriptor$= 1.initialize(ExternalScanOperatorDescriptor.java:62) ~[asterix-external-dat= a.jar:6.6.0-11077] > at org.apache.hyracks.api.rewriter.runtime.SuperActivityOperatorNodePush= able.lambda$runInParallel$8(SuperActivityOperatorNodePushable.java:228) ~[h= yracks-api.jar:6.6.0-11077] > at java.util.concurrent.FutureTask.run(Unknown Source) [?:?] > at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [?:= ?] > at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [?= :?] > at java.lang.Thread.run(Unknown Source) [?:?] > Caused by: java.lang.IllegalArgumentException: newPosition > limit: (409= 6 > 1048) > at java.nio.Buffer.createPositionException(Unknown Source) ~[?:?] > at java.nio.Buffer.position(Unknown Source) ~[?:?] > at java.nio.ByteBuffer.position(Unknown Source) ~[?:?] > at java.nio.ByteBuffer.position(Unknown Source) ~[?:?] > at org.apache.asterix.external.input.stream.AsterixInputStreamReader.rea= d(AsterixInputStreamReader.java:103) ~[asterix-external-data.jar:6.6.0-1107= 7] > at org.apache.asterix.external.input.stream.AsterixInputStreamReader.rea= d(AsterixInputStreamReader.java:67) ~[asterix-external-data.jar:6.6.0-11077= ] > at org.apache.asterix.external.input.record.reader.stream.LineRecordRead= er.hasNext(LineRecordReader.java:101) ~[asterix-external-data.jar:6.6.0-110= 77] > at org.apache.asterix.external.dataflow.RecordDataFlowController.start(R= ecordDataFlowController.java:49) ~[asterix-external-data.jar:6.6.0-11077] > ... 7 more{code} -- This message was sent by Atlassian Jira (v8.3.4#803005)