ranger-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mad...@apache.org
Subject [1/2] incubator-ranger git commit: RANGER-203: Removed CustomizedMapDeserializer for RangerService.configs
Date Thu, 08 Jan 2015 06:12:53 GMT
Repository: incubator-ranger
Updated Branches:
  refs/heads/stack bd8c234c3 -> 23da1956e


RANGER-203: Removed CustomizedMapDeserializer for RangerService.configs


Project: http://git-wip-us.apache.org/repos/asf/incubator-ranger/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ranger/commit/83ef5e86
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ranger/tree/83ef5e86
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ranger/diff/83ef5e86

Branch: refs/heads/stack
Commit: 83ef5e8644216c00648f23ba11509026675809e2
Parents: bd8c234
Author: Gautam Borad <gborad@gmail.com>
Authored: Wed Jan 7 22:11:34 2015 -0800
Committer: Madhan Neethiraj <madhan@apache.org>
Committed: Wed Jan 7 22:11:34 2015 -0800

----------------------------------------------------------------------
 .../manager/CustomizedMapDeserializer.java      | 50 --------------------
 1 file changed, 50 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-ranger/blob/83ef5e86/plugin-common/src/main/java/org/apache/ranger/plugin/manager/CustomizedMapDeserializer.java
----------------------------------------------------------------------
diff --git a/plugin-common/src/main/java/org/apache/ranger/plugin/manager/CustomizedMapDeserializer.java
b/plugin-common/src/main/java/org/apache/ranger/plugin/manager/CustomizedMapDeserializer.java
deleted file mode 100644
index 9ab3247..0000000
--- a/plugin-common/src/main/java/org/apache/ranger/plugin/manager/CustomizedMapDeserializer.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- * 
- * http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-
-package org.apache.ranger.plugin.manager;
-
-
-import java.io.IOException;
-import java.util.HashMap;
-import java.util.Map;
-
-import org.codehaus.jackson.JsonParser;
-import org.codehaus.jackson.JsonProcessingException;
-import org.codehaus.jackson.JsonToken;
-import org.codehaus.jackson.map.DeserializationContext;
-import org.codehaus.jackson.map.JsonDeserializer;
-import org.codehaus.jackson.map.ObjectMapper;
-import org.codehaus.jackson.type.TypeReference;
-
-
-public class CustomizedMapDeserializer extends JsonDeserializer<Map<Object, Object>>
{
-
-        @Override
-        public Map<Object, Object> deserialize(JsonParser jp, DeserializationContext
arg1) throws IOException,
-                JsonProcessingException {
-                ObjectMapper mapper = (ObjectMapper) jp.getCodec();
-                if (jp.getCurrentToken().equals(JsonToken.START_OBJECT)) {
-                        return mapper.readValue(jp, new TypeReference<Map<Object, Object>>()
{ });
-                } else {
-                        // consume this stream
-                        mapper.readTree(jp);
-                        return new HashMap<Object, Object>();
-                }
-        }
-}


Mime
View raw message