diff --git a/lib/java/gradle/generateTestThrift.gradle b/lib/java/gradle/generateTestThrift.gradle
index b8a963d..e851547 100644
--- a/lib/java/gradle/generateTestThrift.gradle
+++ b/lib/java/gradle/generateTestThrift.gradle
@@ -86,6 +86,7 @@
     thriftCompile(it, 'EnumContainersTest.thrift')
     thriftCompile(it, 'JavaBinaryDefault.thrift')
     thriftCompile(it, 'VoidMethExceptionsTest.thrift')
+    thriftCompile(it, 'AnnotationTest.thrift')
     thriftCompile(it, 'partial/thrift_test_schema.thrift')
 }
 
@@ -133,3 +134,12 @@
 
     thriftCompile(it, 'UnsafeTypes.thrift', 'java:unsafe_binaries', genUnsafeSrc)
 }
+
+task generateWithAnnotationMetadata(group: 'Build') {
+    description = 'Generate with annotation enabled and add to the default source'
+    generate.dependsOn it
+
+    ext.outputBuffer = new ByteArrayOutputStream()
+
+    thriftCompile(it, 'JavaAnnotationTest.thrift', 'java:annotations_as_metadata', genSrc)
+}
diff --git a/lib/java/src/main/java/org/apache/thrift/meta_data/FieldMetaData.java b/lib/java/src/main/java/org/apache/thrift/meta_data/FieldMetaData.java
index 7534390..5691f83 100644
--- a/lib/java/src/main/java/org/apache/thrift/meta_data/FieldMetaData.java
+++ b/lib/java/src/main/java/org/apache/thrift/meta_data/FieldMetaData.java
@@ -19,9 +19,14 @@
 
 package org.apache.thrift.meta_data;
 
+import java.util.AbstractMap;
+import java.util.Arrays;
+import java.util.Collections;
 import java.util.HashMap;
 import java.util.Map;
 import java.util.concurrent.ConcurrentHashMap;
+import java.util.stream.Collectors;
+import java.util.stream.Stream;
 
 import org.apache.thrift.TBase;
 import org.apache.thrift.TFieldIdEnum;
@@ -42,18 +47,28 @@
   public final String fieldName;
   public final byte requirementType;
   public final FieldValueMetaData valueMetaData;
-  private static final Map<Class<? extends TBase>, Map<? extends TFieldIdEnum, FieldMetaData>> structMap;
-  
-  static {
-    structMap = new ConcurrentHashMap<Class<? extends TBase>, Map<? extends TFieldIdEnum, FieldMetaData>>();
-  }
-  
+  private final Map<String, String> fieldAnnotations;
+  private static final Map<Class<? extends TBase>, Map<? extends TFieldIdEnum, FieldMetaData>> structMap = new ConcurrentHashMap<>();
+
   public FieldMetaData(String name, byte req, FieldValueMetaData vMetaData){
-    this.fieldName = name;
-    this.requirementType = req;
-    this.valueMetaData = vMetaData;
+    this(name, req, vMetaData, Collections.emptyMap());
   }
-  
+
+  public FieldMetaData(String fieldName, byte requirementType, FieldValueMetaData valueMetaData, Map<String, String> fieldAnnotations) {
+    this.fieldName = fieldName;
+    this.requirementType = requirementType;
+    this.valueMetaData = valueMetaData;
+    this.fieldAnnotations = fieldAnnotations;
+  }
+
+  /**
+   * @return an unmodifiable view of the annotations for this field, empty if no annotations present or code gen param
+   * is not turned on
+   */
+  public Map<String, String> getFieldAnnotations() {
+    return Collections.unmodifiableMap(fieldAnnotations);
+  }
+
   public static void addStructMetaDataMap(Class<? extends TBase> sClass, Map<? extends TFieldIdEnum, FieldMetaData> map){
     structMap.put(sClass, map);
   }
diff --git a/lib/java/src/test/java/org/apache/thrift/TestAnnotationMetadata.java b/lib/java/src/test/java/org/apache/thrift/TestAnnotationMetadata.java
new file mode 100644
index 0000000..a9381e6
--- /dev/null
+++ b/lib/java/src/test/java/org/apache/thrift/TestAnnotationMetadata.java
@@ -0,0 +1,61 @@
+/*
+ * 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.thrift;
+
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.Map;
+
+import org.apache.thrift.meta_data.FieldMetaData;
+import org.junit.Assert;
+import org.junit.Test;
+import thrift.test.OneOfEachBeans;
+import thrift.test.annotations.OneOfEachBeansWithAnnotations;
+
+public class TestAnnotationMetadata {
+
+    @Test
+    public void testWithoutParamShouldGenerateEmpty() {
+        Map<? extends TFieldIdEnum, FieldMetaData> structMetaDataMap = FieldMetaData.getStructMetaDataMap(OneOfEachBeans.class);
+        {
+            Map<String, String> metadata = structMetaDataMap.get(OneOfEachBeans._Fields.I16_LIST).getFieldAnnotations();
+            Assert.assertEquals(Collections.emptyMap(), metadata);
+        }
+        {
+            Map<String, String> metadata = structMetaDataMap.get(OneOfEachBeans._Fields.A_BITE).getFieldAnnotations();
+            Assert.assertEquals(Collections.emptyMap(), metadata);
+        }
+    }
+
+    @Test
+    public void testGeneratedAnnotations() {
+        Map<? extends TFieldIdEnum, FieldMetaData> structMetaDataMap = FieldMetaData.getStructMetaDataMap(OneOfEachBeansWithAnnotations.class);
+        {
+            Map<String, String> metadata = structMetaDataMap.get(OneOfEachBeansWithAnnotations._Fields.I16_LIST).getFieldAnnotations();
+            Assert.assertEquals(Collections.emptyMap(), metadata);
+        }
+        {
+            Map<String, String> metadata = structMetaDataMap.get(OneOfEachBeansWithAnnotations._Fields.A_BITE).getFieldAnnotations();
+            Map<String, String> expected = new HashMap<>();
+            expected.put("compression", "false");
+            Assert.assertEquals(expected, metadata);
+        }
+    }
+}
diff --git a/lib/java/src/test/resources/JavaAnnotationTest.thrift b/lib/java/src/test/resources/JavaAnnotationTest.thrift
new file mode 100644
index 0000000..925a05d
--- /dev/null
+++ b/lib/java/src/test/resources/JavaAnnotationTest.thrift
@@ -0,0 +1,34 @@
+/*
+ * 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.
+ */
+
+namespace java thrift.test.annotations
+
+struct OneOfEachBeansWithAnnotations {
+  1: bool boolean_field,
+  2: byte a_bite (compression = "false"),
+  3: i16 integer16 (must_be_postive = "true"),
+  4: i32 integer32,
+  5: i64 integer64,
+  6: double double_precision (nan_inf_allowed = "false"),
+  7: string some_characters,
+  8: binary base64,
+  9: list<byte> byte_list (non_empty = "true"),
+  10: list<i16> i16_list,
+  11: list<i64> i64_list
+}
