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 9A567200C28 for ; Mon, 13 Mar 2017 13:17:34 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 98E4E160B6C; Mon, 13 Mar 2017 12:17:34 +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 E08C5160B60 for ; Mon, 13 Mar 2017 13:17:33 +0100 (CET) Received: (qmail 8450 invoked by uid 500); 13 Mar 2017 12:17:31 -0000 Mailing-List: contact user-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hbase.apache.org Delivered-To: mailing list user@hbase.apache.org Received: (qmail 8431 invoked by uid 99); 13 Mar 2017 12:17:30 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 13 Mar 2017 12:17:30 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id 7CF4D1803A1 for ; Mon, 13 Mar 2017 12:17:30 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.379 X-Spam-Level: X-Spam-Status: No, score=0.379 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd3-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id oleoC0ylJPDz for ; Mon, 13 Mar 2017 12:17:29 +0000 (UTC) Received: from mail-qk0-f181.google.com (mail-qk0-f181.google.com [209.85.220.181]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id 375105F659 for ; Mon, 13 Mar 2017 12:17:29 +0000 (UTC) Received: by mail-qk0-f181.google.com with SMTP id y76so220544638qkb.0 for ; Mon, 13 Mar 2017 05:17:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=L3ysW7baN8gbkQjrYApFuh6VqOEKKw1WavUFZLSfRLM=; b=MSV8VNiZFoW7JbWfKA7j1dbU4S1y6E++kc0e9dL58mI1LjQ/YY5WfZN8NON28CYAFy 8TC8Eng74GW2jh9IDpuMZcOfSMw6fp7DZrNaO5DpCp+1D89l8/WM6dWtCnB7poHMUzVG PJdnzBa/wgCnJi3IHyJvjykZxPOPEOvupo2lcimX4YWos/3MlW9dwd5zxDvYytEFl6Wl +F01it/kHBFrwH69rGFVLZUaZHvNhwRs3KPfxkDn0jUO1LH3oHRpfsTDzad8si8LLiHR cZrkMR+AWQneqSd5AI4lE0ENG5ja7BM9R/KjcLWNL6DoNxG8kLJzvoODL5ut8Yhrf3/j bYlQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=L3ysW7baN8gbkQjrYApFuh6VqOEKKw1WavUFZLSfRLM=; b=IByNgbfxDnPqc+FOP3Npk3s/Q2IAZD7JQKOYXXE+xRcfIEkNny/ZQkrqiG0DoGqz/7 8WwJFP7J7BZRrfvbd7Z1IOudju5NZHGdpMKkQ4fEl/hGwai6D33bOyjXsKlSYDRSX7f3 qNRYqKtXf/LkpJoO1EtY/yjjmQMSHvADgYdDL+IFljoz95xAWdvDKrquMva3qOUyoUnj yOHUoQynvI6Ktep+/PC6dD2LpretpU4YfOep8c5S0VxFFq29hSL+aakvTFDZZHLY1pdd JJhkwv5picU0jHisefsDCS6ZTUJBU+jb1C5RGJ/fMAIq+zd6X+jq/EUPQHzc/zq2IEdp y1Gg== X-Gm-Message-State: AMke39mKKFQwOPxQqWCigpfuYOF+XS5PBCbaoxYIaVsfsdS2SK/kIcmDifUfnNWeTtABu3MRDz5BLpYPms92+w== X-Received: by 10.55.210.70 with SMTP id f67mr30092552qkj.304.1489407130194; Mon, 13 Mar 2017 05:12:10 -0700 (PDT) MIME-Version: 1.0 Received: by 10.12.175.80 with HTTP; Mon, 13 Mar 2017 05:12:09 -0700 (PDT) From: =?UTF-8?Q?Kristoffer_Sj=C3=B6gren?= Date: Mon, 13 Mar 2017 13:12:09 +0100 Message-ID: Subject: HBase + Spark join To: user@hbase.apache.org Content-Type: text/plain; charset=UTF-8 archived-at: Mon, 13 Mar 2017 12:17:34 -0000 Hi I want to join a Spark RDD with an HBase table. Im familiar with the different connectors available but couldn't find this functionality. The idea I have is to first sort the RDD according to a byte[] key [1] and rdd.mapPartitions so that I each partition contains a unique and sequentially sorted range of keys that lines up with the key order in HBase. I should mention that the RDD will always contain almost all the keys that are stored in HBase, so full tables scans are fine. Unfortunately, Spark cannot sort native Java byte[]. And i'm also not sure if mapPartitions really maintain the total sort order of the original RDD. Any suggestions? Cheers, -Kristoffer [1] Guava UnsignedBytes.lexicographicalComparator