Return-Path: X-Original-To: apmail-hadoop-common-issues-archive@minotaur.apache.org Delivered-To: apmail-hadoop-common-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 1EAF69643 for ; Sat, 25 Feb 2012 00:44:13 +0000 (UTC) Received: (qmail 86623 invoked by uid 500); 25 Feb 2012 00:44:12 -0000 Delivered-To: apmail-hadoop-common-issues-archive@hadoop.apache.org Received: (qmail 86581 invoked by uid 500); 25 Feb 2012 00:44:12 -0000 Mailing-List: contact common-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: common-issues@hadoop.apache.org Delivered-To: mailing list common-issues@hadoop.apache.org Received: (qmail 86568 invoked by uid 99); 25 Feb 2012 00:44:12 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 25 Feb 2012 00:44:12 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 25 Feb 2012 00:44:10 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 960213374CD for ; Sat, 25 Feb 2012 00:43:49 +0000 (UTC) Date: Sat, 25 Feb 2012 00:43:49 +0000 (UTC) From: "Alejandro Abdelnur (Commented) (JIRA)" To: common-issues@hadoop.apache.org Message-ID: <445924226.18152.1330130629615.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <564297893.7423.1329959628953.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Commented] (HADOOP-8104) Inconsistent Jackson versions 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/HADOOP-8104?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13216180#comment-13216180 ] Alejandro Abdelnur commented on HADOOP-8104: -------------------------------------------- @Enis first comment, my patch is adding those jackson artifacts to the *dependency management* section, this means that they are not added to Hadoop classpath unless somebody add them to the a *dependencies* section explicitly or they are pulled as transitive dependency. In the current case is the later. So, what the addition to the *dependency management* section does is to force a particular version in case somebody is bring the artifact in. Hope this clarifies. > Inconsistent Jackson versions > ----------------------------- > > Key: HADOOP-8104 > URL: https://issues.apache.org/jira/browse/HADOOP-8104 > Project: Hadoop Common > Issue Type: Bug > Reporter: Colin Patrick McCabe > Assignee: Colin Patrick McCabe > Attachments: HADOOP-7470.patch, HADOOP-8104.patch, dependency-tree-old.txt > > > This is a maven build issue. > Jersey 1.8 is pulling in version 1.7.1 of Jackson. Meanwhile, we are manually specifying that we want version 1.8 of Jackson in the POM files. This causes a conflict where Jackson produces unexpected results when serializing Map objects. > How to reproduce: try this code: > {quote} > ObjectMapper mapper = new ObjectMapper(); > Map m = new HashMap(); > mapper.writeValue(new File("foo"), m); > {quote} > You will get an exception: > {quote} > Exception in thread "main" java.lang.NoSuchMethodError: org.codehaus.jackson.type.JavaType.isMapLikeType()Z > at org.codehaus.jackson.map.ser.BasicSerializerFactory.buildContainerSerializer(BasicSerializerFactory.java:396) > at org.codehaus.jackson.map.ser.BeanSerializerFactory.createSerializer(BeanSerializerFactory.java:267) > {quote} > Basically the inconsistent versions of various Jackson components are causing this NoSuchMethod error. > As far as I know, this only occurs when serializing maps-- that's why it hasn't been found and fixed yet. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira