Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 34AEF200BFE for ; Mon, 16 Jan 2017 23:44:38 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 334FA160B41; Mon, 16 Jan 2017 22:44:38 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 7E833160B28 for ; Mon, 16 Jan 2017 23:44:37 +0100 (CET) Received: (qmail 11308 invoked by uid 500); 16 Jan 2017 22:44:31 -0000 Mailing-List: contact dev-help@kafka.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@kafka.apache.org Delivered-To: mailing list dev@kafka.apache.org Received: (qmail 11297 invoked by uid 99); 16 Jan 2017 22:44:31 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 16 Jan 2017 22:44:31 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 3CD35C00B6 for ; Mon, 16 Jan 2017 22:44:31 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -1.199 X-Spam-Level: X-Spam-Status: No, score=-1.199 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, KAM_LAZY_DOMAIN_SECURITY=1, RP_MATCHES_RCVD=-2.999] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id 8fweRSmpR5ma for ; Mon, 16 Jan 2017 22:44:29 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id DE0D15FB33 for ; Mon, 16 Jan 2017 22:44:28 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 3D9ADE58A3 for ; Mon, 16 Jan 2017 22:44:28 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 67D4F25287 for ; Mon, 16 Jan 2017 22:44:26 +0000 (UTC) Date: Mon, 16 Jan 2017 22:44:26 +0000 (UTC) From: "Bill Bejeck (JIRA)" To: dev@kafka.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (KAFKA-4468) Correctly calculate the window end timestamp after read from state stores MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Mon, 16 Jan 2017 22:44:38 -0000 [ https://issues.apache.org/jira/browse/KAFKA-4468?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15824683#comment-15824683 ] Bill Bejeck commented on KAFKA-4468: ------------------------------------ Hi, Eno - I was, but for a couple of reasons I unassigned myself from this a few days ago. It's all yours if you want. Thanks for asking. > Correctly calculate the window end timestamp after read from state stores > ------------------------------------------------------------------------- > > Key: KAFKA-4468 > URL: https://issues.apache.org/jira/browse/KAFKA-4468 > Project: Kafka > Issue Type: Bug > Components: streams > Reporter: Guozhang Wang > Labels: architecture > > When storing the WindowedStore on the persistent KV store, we only use the start timestamp of the window as part of the combo-key as (start-timestamp, key). The reason that we do not add the end-timestamp as well is that we can always calculate it from the start timestamp + window_length, and hence we can save 8 bytes per key on the persistent KV store. > However, after read it (via {{WindowedDeserializer}}) we do not set its end timestamp correctly but just read it as an {{UnlimitedWindow}}. We should fix this by calculating its end timestamp as mentioned above. -- This message was sent by Atlassian JIRA (v6.3.4#6332)