Return-Path: X-Original-To: apmail-flink-dev-archive@www.apache.org Delivered-To: apmail-flink-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 412B217438 for ; Tue, 7 Apr 2015 08:03:01 +0000 (UTC) Received: (qmail 99705 invoked by uid 500); 7 Apr 2015 08:03:01 -0000 Delivered-To: apmail-flink-dev-archive@flink.apache.org Received: (qmail 99647 invoked by uid 500); 7 Apr 2015 08:03:00 -0000 Mailing-List: contact dev-help@flink.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@flink.apache.org Delivered-To: mailing list dev@flink.apache.org Received: (qmail 99630 invoked by uid 99); 7 Apr 2015 08:03:00 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 07 Apr 2015 08:03:00 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of fhueske@gmail.com designates 209.85.217.174 as permitted sender) Received: from [209.85.217.174] (HELO mail-lb0-f174.google.com) (209.85.217.174) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 07 Apr 2015 08:02:55 +0000 Received: by lboc7 with SMTP id c7so36438313lbo.1 for ; Tue, 07 Apr 2015 01:01:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=OgEho07WIZyrppzQrPqVZNT+hHljyuBqDrKx2MEx9Bg=; b=ZLr1T0cJCw+iUeYt1/jIiPumUXqeO3RRcvkQAHAULRUWN8uQ7TzClzzOh7+q//6Pr4 Ow8fvPYxn8UphOi+GzRbXABvVVVbAiKu5KGwBIa7xXEDL92xio+g5IBYXXE3qWCR2kf/ SM+yF+Ub37n+JsngRMFTp3GOLu62bdk9vf1G1XgllADU4civlnNIr762aF+C+z4B5W7I imE/KGRfBf7Fz++XDv2th72qaaTP5khx2D/3yhurXgoKRqLeDKPcuAV+MtO5BUHevXNB 4QZukh1va88+HZ4tdbvMIo578zhZZdyNxXwkXJtfqSDADK/uM5LyQojlJfAUb0EeTFnk jpzw== MIME-Version: 1.0 X-Received: by 10.152.5.7 with SMTP id o7mr15187647lao.51.1428393709106; Tue, 07 Apr 2015 01:01:49 -0700 (PDT) Received: by 10.152.135.131 with HTTP; Tue, 7 Apr 2015 01:01:49 -0700 (PDT) In-Reply-To: References: Date: Tue, 7 Apr 2015 10:01:49 +0200 Message-ID: Subject: Re: [QUESTION] Sort Key Types From: Fabian Hueske To: "dev@flink.apache.org" Content-Type: multipart/alternative; boundary=089e01419d8aa17dfa05131dd3f7 X-Virus-Checked: Checked by ClamAV on apache.org --089e01419d8aa17dfa05131dd3f7 Content-Type: text/plain; charset=UTF-8 Regular keys differ from sort keys in that they can be (somehow) sorted, but their order is not necessarily "intuitive". So regular keys are sufficient for sort-based grouping, but not for explicit sorting (groupSort, partitionSort, outputSort). Right now, this difference is only relevant for POJOs. Since the order of POJO fields is not (well) defined and they are ordered based on all their fields, the resulting order is not well defined either. We can add support for sorting POJOs if these implement Comparable or somehow define the order of their fields (as proposed in FLINK-1665) 2015-04-06 14:34 GMT+02:00 Stephan Ewen : > I as that a recent commit introduced the notion of sort key types, which > have a well defined order. > > What is the difference to a regular key? Regular keys are also sortable, so > why the distinction? > --089e01419d8aa17dfa05131dd3f7--