private void filterMetadata(FetchEmitTuple t, List<Metadata> metadataList) {
        MetadataFilter filter = t.getParseContext().get(MetadataFilter.class);
        if (filter == null) {
            filter = tikaConfig.getMetadataFilter();
        }
        for (Metadata m : metadataList) {
            try {
                filter.filter(m);
            } catch (TikaException e) {
                LOG.warn("failed to filter metadata", e);
            }
        }
    }
returns stack trace if there was a container exception or empty string
if there was no stacktrace

@param t
@param metadataList
@return
tika-core/src/main/java/org/apache/tika/pipes/PipesServer.java