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 2E296200BF0 for ; Fri, 30 Dec 2016 08:28:33 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 285B7160B32; Fri, 30 Dec 2016 07:28:33 +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 738B9160B24 for ; Fri, 30 Dec 2016 08:28:32 +0100 (CET) Received: (qmail 56639 invoked by uid 500); 30 Dec 2016 07:28:31 -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 56626 invoked by uid 99); 30 Dec 2016 07:28:31 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 30 Dec 2016 07:28:31 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id C43A41A05D7 for ; Fri, 30 Dec 2016 07:28:30 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.129 X-Spam-Level: ** X-Spam-Status: No, score=2.129 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd2-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 (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id IjjYSvX8BZgM for ; Fri, 30 Dec 2016 07:28:28 +0000 (UTC) Received: from mail-yw0-f179.google.com (mail-yw0-f179.google.com [209.85.161.179]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id A48535F30A for ; Fri, 30 Dec 2016 07:28:27 +0000 (UTC) Received: by mail-yw0-f179.google.com with SMTP id r204so221522457ywb.0 for ; Thu, 29 Dec 2016 23:28:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=kvf2VOL5f3nJGIT3kg+9A7F7URhT6WAitOx/7iavyik=; b=p5CGWyJOde2ow1T05DqQwwogEx22bDbuDCM1dytwyYgE9fZqi7VZ9Zj4l6x79HjTC/ EJlNQ13tAuyhaYpJljb+NfluNut7dIq5/93A0dzP83GCWta9lOI3KdIKdbsA8ggpGvG3 vJ43pa9dB+5ygqh2zPKQd0oLASdpN9lg6c0zoqRn64a9GhZpMxpGi+zrIvxBJKFPU86z /AGveiS17Bk9vk/GDVin9AJ9cfRJYlnOI69tnTHSO92XnoEv3U+6pYwLHahQstXsAcP6 zC7SiLZFnx4o2yBQmj16cSW3RNKdtvcF05JhkNK44T4YG/B5El+bV60v8rfsVC7fGCaj ILxw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=kvf2VOL5f3nJGIT3kg+9A7F7URhT6WAitOx/7iavyik=; b=tnRt5Z1qykdNoFl3o0bG9hl5pq0TmqaH5U+abia+VF+i8w6Ud+H3Vkp998Ojh9pFId jpgxTU0lIes4q7c/ZIFFm91aTryD1Cg3otBlU71MvdJwMrQXviVUgWSvSiABYrsYsHDD 6yf2gfSbjJ2ngpOatJ2WyaK1C5JoGAPybg0OwohFVoGn4lpTC4O133xicZAx//fBCZxf tycOLpp0aKExSsWqL3TForx3kML+MZSjjneWsiXPSOe9f2CPd9y+vm8nsoulPMIs2Lzm 9TGQOIekLGsgFOwqDDMbjGAQZVEor3+Vif2x1vtkuBp/CKfsvldFTe+ugZroNxDzsEsQ LlgA== X-Gm-Message-State: AIkVDXL1/pliYJozMG0/AhKT7Od6IBasqSDeQTK6wuW5mTROqtpsQso8+vFZceOK9/sXcikYPERLjRJdIu5YAQ== X-Received: by 10.129.13.215 with SMTP id 206mr36956893ywn.69.1483082892151; Thu, 29 Dec 2016 23:28:12 -0800 (PST) MIME-Version: 1.0 Received: by 10.37.252.24 with HTTP; Thu, 29 Dec 2016 23:28:11 -0800 (PST) In-Reply-To: References: From: Liang Chen Date: Fri, 30 Dec 2016 15:28:11 +0800 Message-ID: Subject: Re: How to add flink dependency in pom To: dev@flink.apache.org Content-Type: multipart/alternative; boundary=001a1142e2e0f591ae0544db24ed archived-at: Fri, 30 Dec 2016 07:28:33 -0000 --001a1142e2e0f591ae0544db24ed Content-Type: text/plain; charset=UTF-8 Hi Can i do like this : To directly run the below example in my project through adding flink's pom dependency? Thanks. Regards Liang ------------------------------- object WordCount { def main(args: Array[String]) { val params: ParameterTool = ParameterTool.fromArgs(args) // set up execution environment val env = ExecutionEnvironment.getExecutionEnvironment // make parameters available in the web interface env.getConfig.setGlobalJobParameters(params) val text = if (params.has("input")) { env.readTextFile(params.get("input")) } else { println("Executing WordCount example with default input data set.") println("Use --input to specify file input.") env.fromCollection(WordCountData.WORDS) } val counts = text.flatMap { _.toLowerCase.split("\\W+") filter { _.nonEmpty } } .map { (_, 1) } .groupBy(0) .sum(1) if (params.has("output")) { counts.writeAsCsv(params.get("output"), "\n", " ") env.execute("Scala WordCount Example") } else { println("Printing result to stdout. Use --output to specify output path.") counts.print() } } } 2016-12-30 5:10 GMT+08:00 Fabian Hueske : > Hi, > > I assume you have implemented a Flink InputFormat that reads data from > CarbonData and you would like to have an integration test for this > InputFormat which runs on Apache Flink. > Flink includes test utils that start a Flink mini cluster in a single JVM > [1] which might be useful for your use case. This and more testing utils > are included in the following dependency: > > > org.apache.flink > flink-test-utils_2.10 > ${project.version} > test > > > You can also have a look at Flink's own integration tests in the flink-test > [2] Maven module. > > Hope this helps, > Fabian > > [1] > https://github.com/apache/flink/blob/master/flink-test- > utils-parent/flink-test-utils/src/main/java/org/apache/flink/test/util/ > MultipleProgramsTestBase.java > [2] https://github.com/apache/flink/tree/master/flink-tests > > 2016-12-29 17:06 GMT+01:00 Liang Chen : > > > Hi > > > > I am from Apache CarbonData community. > > I plan to do some integration test, take CarbonData as Flink's > source/sink. > > > > Please help and guide, how to add all flink dependency: > > > > > > org.apache.flink > > flink-clients_2.10 > > ${project.version} > > provided > > > > > > > > org.apache.flink > > flink-core > > ${project.version} > > test-jar > > test > > > > > > *any other dependency need to be added ?* > > > > > > Regards > > Liang > > > -- Regards Liang --001a1142e2e0f591ae0544db24ed--