@Override
    public Map<String, ElasticIndexField> getFieldsMap(final ElasticIndexDoc index) {
        final Map<String, FieldMapping> fieldMappings = getFieldMappings(index);
        final Map<String, ElasticIndexField> fieldsMap = new HashMap<>();

        fieldMappings.forEach((key, fieldMeta) -> {
            try {
                String nativeType = getFieldTypeFromMapping(key, fieldMeta);
                final String fieldName = fieldMeta.fullName();
                final boolean indexed = fieldIsIndexed(fieldMeta);

                if (nativeType == null) {
                    return;
                } else if (Kind.Alias.jsonValue().equals(nativeType)) {
                    // Determine the mapping type of the field the alias is referring to
                    try {
                        final String aliasPath = getAliasPathFromMapping(fieldName, fieldMeta);
                        final FieldMapping targetFieldMeta = fieldMappings.get(aliasPath);
                        nativeType = getFieldTypeFromMapping(aliasPath, targetFieldMeta);
                    } catch (Exception e) {
                        LOGGER.error("Could not determine mapping type for alias field '{}'", fieldName);
                    }
                }

                final FieldType type = ElasticNativeTypes.fromNativeType(fieldName, nativeType);
                fieldsMap.put(fieldName, new ElasticIndexField(
                        null,
                        null,
                        null,
                        fieldName,
                        type,
                        nativeType,
                        indexed));
            } catch (UnsupportedTypeException e) {
                LOGGER.debug(e::getMessage, e);
            } catch (Exception e) {
                LOGGER.error(e::getMessage, e);
            }
        });

        return fieldsMap;
    }
Returns an `AbstractField` instance, based on the field's data type
stroom-search/stroom-search-elastic/src/main/java/stroom/search/elastic/search/ElasticSearchProvider.java