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 D04D7200BD0 for ; Wed, 30 Nov 2016 22:19:59 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id CEF87160B28; Wed, 30 Nov 2016 21:19:59 +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 52C1E160B13 for ; Wed, 30 Nov 2016 22:19:59 +0100 (CET) Received: (qmail 67493 invoked by uid 500); 30 Nov 2016 21:19:58 -0000 Mailing-List: contact dev-help@avro.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@avro.apache.org Delivered-To: mailing list dev@avro.apache.org Received: (qmail 67465 invoked by uid 99); 30 Nov 2016 21:19:58 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 30 Nov 2016 21:19:58 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 5A39A2C0453 for ; Wed, 30 Nov 2016 21:19:58 +0000 (UTC) Date: Wed, 30 Nov 2016 21:19:58 +0000 (UTC) From: "Sean Timm (JIRA)" To: dev@avro.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (AVRO-1957) TimeConversions do not implement getRecommendedSchema() MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 30 Nov 2016 21:20:00 -0000 [ https://issues.apache.org/jira/browse/AVRO-1957?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15709801#comment-15709801 ] Sean Timm commented on AVRO-1957: --------------------------------- If possible, it would be nice to get this in to 1.8.2. It is a fairly simple fix with PR and unit test. > TimeConversions do not implement getRecommendedSchema() > ------------------------------------------------------- > > Key: AVRO-1957 > URL: https://issues.apache.org/jira/browse/AVRO-1957 > Project: Avro > Issue Type: Bug > Affects Versions: 1.8.1 > Reporter: Sean Timm > > org.apache.avro.data.TimeConversions.TimestampConversion and other date and time conversions do not implement getRecommendedSchema(). When trying to dynamically generate an Avro schema from a pojo that contains a DateTime object using ReflectData, I get an unsupported operation exception. > I think the implementation should be as simple as > {code} > @Override > public Schema getRecommendedSchema() { > return LogicalTypes.timestampMillis().addToSchema(Schema.create(Schema.Type.LONG)); > } > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)