From 76ef10e0834f67ab5f93169e4c8d56d14eb69993 Mon Sep 17 00:00:00 2001 From: Matt Dailey Date: Mon, 14 Aug 2017 12:12:04 -0400 Subject: [PATCH] [java][api] Use AnnotationIntrospectorPair over deprecated class * Similar to Issue #35 and PR #49, but without the changes to the Jackson dependency itself --- java/src/main/java/com/cloudera/api/ApiObjectMapper.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/java/src/main/java/com/cloudera/api/ApiObjectMapper.java b/java/src/main/java/com/cloudera/api/ApiObjectMapper.java index 5e55b2c9..747be861 100644 --- a/java/src/main/java/com/cloudera/api/ApiObjectMapper.java +++ b/java/src/main/java/com/cloudera/api/ApiObjectMapper.java @@ -16,10 +16,10 @@ package com.cloudera.api; -import com.fasterxml.jackson.databind.AnnotationIntrospector; import com.fasterxml.jackson.databind.MapperFeature; import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.SerializationFeature; +import com.fasterxml.jackson.databind.introspect.AnnotationIntrospectorPair; import com.fasterxml.jackson.module.jaxb.JaxbAnnotationIntrospector; import java.text.DateFormat; @@ -38,7 +38,7 @@ public ApiObjectMapper() { // Allow JAX-B annotations. setAnnotationIntrospector( - new AnnotationIntrospector.Pair( + new AnnotationIntrospectorPair( getSerializationConfig().getAnnotationIntrospector(), new JaxbAnnotationIntrospector()));