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 C3789200D1E for ; Wed, 4 Oct 2017 02:00:14 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id C1EAD160BD5; Wed, 4 Oct 2017 00:00:14 +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 13B401609DE for ; Wed, 4 Oct 2017 02:00:13 +0200 (CEST) Received: (qmail 48088 invoked by uid 500); 4 Oct 2017 00:00:13 -0000 Mailing-List: contact jira-help@kafka.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: jira@kafka.apache.org Delivered-To: mailing list jira@kafka.apache.org Received: (qmail 48077 invoked by uid 99); 4 Oct 2017 00:00:13 -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; Wed, 04 Oct 2017 00:00:13 +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 41AFD1A2C96 for ; Wed, 4 Oct 2017 00:00:12 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -100.001 X-Spam-Level: X-Spam-Status: No, score=-100.001 tagged_above=-999 required=6.31 tests=[RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id uyuSo8R9b3vX for ; Wed, 4 Oct 2017 00:00:07 +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 299045FB9F for ; Wed, 4 Oct 2017 00:00:07 +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 ADB8EE08F5 for ; Wed, 4 Oct 2017 00:00:05 +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 A450B242D5 for ; Wed, 4 Oct 2017 00:00:02 +0000 (UTC) Date: Wed, 4 Oct 2017 00:00:02 +0000 (UTC) From: "Stephane Maarek (JIRA)" To: jira@kafka.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (KAFKA-6007) Connect can't validate against transforms in plugins.path MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 04 Oct 2017 00:00:14 -0000 Stephane Maarek created KAFKA-6007: -------------------------------------- Summary: Connect can't validate against transforms in plugins.path Key: KAFKA-6007 URL: https://issues.apache.org/jira/browse/KAFKA-6007 Project: Kafka Issue Type: Bug Affects Versions: 0.11.0.1 Reporter: Stephane Maarek Kafka Connect can't validate a custom transformation if placed in plugins path. Here's the output I get on the validate call: {code:java} Invalid value com.mycorp.kafka.transforms.impl.FlattenSinkRecord for configuration transforms.Flat.type: Class com.mycorp.kafka.transforms.impl.FlattenSinkRecord could not be found. Invalid value null for configuration transforms.Flat.type: Not a Transformation "recommended_values": [ "com.mycorp.kafka.transforms.Flatten$Key", "com.mycorp.kafka.transforms.Flatten$Value", "com.mycorp.kafka.transforms.impl.FlattenSinkRecord", "org.apache.kafka.connect.transforms.Cast$Key", "org.apache.kafka.connect.transforms.Cast$Value", "org.apache.kafka.connect.transforms.ExtractField$Key", "org.apache.kafka.connect.transforms.ExtractField$Value", "org.apache.kafka.connect.transforms.Flatten$Key", "org.apache.kafka.connect.transforms.Flatten$Value", "org.apache.kafka.connect.transforms.HoistField$Key", "org.apache.kafka.connect.transforms.HoistField$Value", "org.apache.kafka.connect.transforms.InsertField$Key", "org.apache.kafka.connect.transforms.InsertField$Value", "org.apache.kafka.connect.transforms.MaskField$Key", "org.apache.kafka.connect.transforms.MaskField$Value", "org.apache.kafka.connect.transforms.RegexRouter", "org.apache.kafka.connect.transforms.ReplaceField$Key", "org.apache.kafka.connect.transforms.ReplaceField$Value", "org.apache.kafka.connect.transforms.SetSchemaMetadata$Key", "org.apache.kafka.connect.transforms.SetSchemaMetadata$Value", "org.apache.kafka.connect.transforms.TimestampConverter$Key", "org.apache.kafka.connect.transforms.TimestampConverter$Value", "org.apache.kafka.connect.transforms.TimestampRouter", "org.apache.kafka.connect.transforms.ValueToKey"], {code} As you can see the class appear in the recommended values (!) but can't be picked up on the validate call. I believe it's because the recommender implements class discovery using plugins: https://github.com/apache/kafka/blob/trunk/connect/runtime/src/main/java/org/apache/kafka/connect/runtime/ConnectorConfig.java#L194 But the class inference itself doesn't: https://github.com/apache/kafka/blob/trunk/connect/runtime/src/main/java/org/apache/kafka/connect/runtime/ConnectorConfig.java#L199 (I'm not an expert in class loading though, just a guess... Unsure how to fix) A quick fix is to add the transformations in the ClassPath itself, but that defeats the point a bit. -- This message was sent by Atlassian JIRA (v6.4.14#64029)