Return-Path: Delivered-To: apmail-hadoop-avro-dev-archive@minotaur.apache.org Received: (qmail 56834 invoked from network); 16 Oct 2009 03:19:05 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 16 Oct 2009 03:19:05 -0000 Received: (qmail 90601 invoked by uid 500); 16 Oct 2009 03:19:04 -0000 Delivered-To: apmail-hadoop-avro-dev-archive@hadoop.apache.org Received: (qmail 90514 invoked by uid 500); 16 Oct 2009 03:19:04 -0000 Mailing-List: contact avro-dev-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: avro-dev@hadoop.apache.org Delivered-To: mailing list avro-dev@hadoop.apache.org Received: (qmail 90503 invoked by uid 99); 16 Oct 2009 03:19:04 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Oct 2009 03:19:04 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Oct 2009 03:18:52 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id CD537234C045 for ; Thu, 15 Oct 2009 20:18:31 -0700 (PDT) Message-ID: <1883912455.1255663111825.JavaMail.jira@brutus> Date: Thu, 15 Oct 2009 20:18:31 -0700 (PDT) From: "Philip Zeyliger (JIRA)" To: avro-dev@hadoop.apache.org Subject: [jira] Updated: (AVRO-152) Adding "doc" to record schemas, a la javadoc field and class comments. In-Reply-To: <40529676.1255662151279.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/AVRO-152?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Philip Zeyliger updated AVRO-152: --------------------------------- Attachment: AVRO-149.patch.txt If you want to follow along how this patch developed, see http://github.com/philz/avro/tree/docs This patch, which won't apply without AVRO-149 (though I could make it independent, if that proves to be useful; I sense that 149 will go in first, though), does the following: * Updates the spec to understand "doc" for records (both for the record class and its fields) and enums (only for the enum class). I haven't dealt with the enum values themselves, because they're specified as an array, so don't have a natural place to put the "doc". I could make it a parallel array, of course, but for now I've left it off. I've also not annotated protocols with "docs", though they deserve the same treatment. * Everywhere where Schema and Field previous just had name, there's now "name, doc". That code was largely limited to Schema.java, so it wasn't a big deal. * I did minor refactoring and clean-up in Schema.java, and made TestSchema.java run all of its schemas through the SpecificCompiler. * I changed SpecificCompiler to output to a String, separating the generation, and the file-writing. Performance isn't critical here, and this let me debug and test the actual code generation, without dealing with File IO. * I fixed a random bug in TestReflect, where the equals() method was wrong, and fixed a bug in TestValidatingIO, where I asserted that it is nonsense to have a fixed field of 0 bytes. > Adding "doc" to record schemas, a la javadoc field and class comments. > ---------------------------------------------------------------------- > > Key: AVRO-152 > URL: https://issues.apache.org/jira/browse/AVRO-152 > Project: Avro > Issue Type: New Feature > Reporter: Philip Zeyliger > Assignee: Philip Zeyliger > Attachments: AVRO-149.patch.txt > > > The patch to follow adds "doc" to the understood schema language (for records and enums), and uses said doc when it generates java in SpecificCompiler. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.