Return-Path: X-Original-To: apmail-apex-dev-archive@minotaur.apache.org Delivered-To: apmail-apex-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7EF151871C for ; Tue, 26 Jan 2016 23:30:51 +0000 (UTC) Received: (qmail 92879 invoked by uid 500); 26 Jan 2016 23:30:51 -0000 Delivered-To: apmail-apex-dev-archive@apex.apache.org Received: (qmail 92811 invoked by uid 500); 26 Jan 2016 23:30:51 -0000 Mailing-List: contact dev-help@apex.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@apex.incubator.apache.org Delivered-To: mailing list dev@apex.incubator.apache.org Received: (qmail 92800 invoked by uid 99); 26 Jan 2016 23:30:51 -0000 Received: from Unknown (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 Jan 2016 23:30:51 +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 D5A01C0D4B for ; Tue, 26 Jan 2016 23:30:50 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.227 X-Spam-Level: * X-Spam-Status: No, score=1.227 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-0.554, URIBL_BLOCKED=0.001] autolearn=disabled Received: from mx1-us-east.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id kT1zDmV8h00Y for ; Tue, 26 Jan 2016 23:30:41 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-us-east.apache.org (ASF Mail Server at mx1-us-east.apache.org) with SMTP id E0D3D439AC for ; Tue, 26 Jan 2016 23:30:40 +0000 (UTC) Received: (qmail 91984 invoked by uid 99); 26 Jan 2016 23:30:40 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 Jan 2016 23:30:40 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 4F7172C1F77 for ; Tue, 26 Jan 2016 23:30:40 +0000 (UTC) Date: Tue, 26 Jan 2016 23:30:40 +0000 (UTC) From: "ASF GitHub Bot (JIRA)" To: dev@apex.incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (APEXMALHAR-1984) Operators that use Kryo directly would throw exception in local mode MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/APEXMALHAR-1984?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15118271#comment-15118271 ] ASF GitHub Bot commented on APEXMALHAR-1984: -------------------------------------------- Github user siyuanh commented on a diff in the pull request: https://github.com/apache/incubator-apex-malhar/pull/178#discussion_r50919206 --- Diff: library/src/main/java/com/datatorrent/lib/util/PartitionerUtils.java --- @@ -0,0 +1,63 @@ +/** + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package com.datatorrent.lib.util; + +import java.io.ByteArrayOutputStream; + +import org.apache.commons.io.IOUtils; + +import com.esotericsoftware.kryo.Kryo; +import com.esotericsoftware.kryo.io.Input; +import com.esotericsoftware.kryo.io.Output; + +import com.datatorrent.api.DefaultPartition; +import com.datatorrent.api.Operator; + +/** + * + * A Partitioner Util class that can be used in definePartition method to create operator from existing one + * + * @since 3.4.0 + */ +public class PartitionerUtils --- End diff -- Name it in this way because it is a repeat pattern in definePartition code and developer can easily find this when they want this feature. > Operators that use Kryo directly would throw exception in local mode > -------------------------------------------------------------------- > > Key: APEXMALHAR-1984 > URL: https://issues.apache.org/jira/browse/APEXMALHAR-1984 > Project: Apache Apex Malhar > Issue Type: Bug > Reporter: Siyuan Hua > Assignee: Siyuan Hua > -- This message was sent by Atlassian JIRA (v6.3.4#6332)