code: private Map<String, Field> populateRecordFields(Map<String, Field> fields) {
      if (fields == null) {
        return null;
      }
  
      Map<String, Schema> knownRecordSchemas = Maps.newHashMap();
      knownRecordSchemas.put(recordName, this);
      ImmutableMap.Builder<String, Field> builder = ImmutableMap.builder();
  
      for (Map.Entry<String, Field> fieldEntry : fields.entrySet()) {
        String fieldName = fieldEntry.getKey();
        Field field = fieldEntry.getValue();
        Schema fieldSchema = resolveSchema(field.getSchema(), knownRecordSchemas);
  
        if (fieldSchema == field.getSchema()) {
          builder.put(fieldName, field);
        } else {
          builder.put(fieldName, Field.of(fieldName, fieldSchema));
        }
      }
  
      return builder.build();
    }
docs: Resolves all field schemas.
  
  @param fields All the fields that need to be resolved.
  @return A {@link java.util.Map} which has all the field schemas resolved.
  @see #resolveSchema(Schema, java.util.Map)