public List<Bson> parse(final List<String> filterExpressions,
                            final List<EntityAttribute> attributes) {
        if (filterExpressions == null || filterExpressions.isEmpty()) {
            return List.of();
        }
        final Map<String, List<Filter>> groupedByField = filterExpressions.stream()
                .map(expr -> singleFilterParser.parseSingleExpression(expr, attributes))
                .collect(groupingBy(Filter::field));

        return groupedByField.values().stream()
                .map(grouped -> grouped.stream()
                        .map(Filter::toBson)
                        .collect(Collectors.toList()))
                .map(groupedFilters -> {
                    if (groupedFilters.size() == 1) {
                        return groupedFilters.get(0);
                    } else {
                        return Filters.or(groupedFilters);
                    }
                })
                .toList();
    }
@Test
    void groupsMultipleFilterForTheSameFieldUsingOrLogic() {

        final List<EntityAttribute> attributes = List.of(EntityAttribute.builder()
                        .id("owner")
                        .title("Owner")
                        .filterable(true)
                        .build(),
                EntityAttribute.builder()
                        .id("title")
                        .title("Title")
                        .filterable(true)
                        .build());


        final List<Bson> expectedResult = List.of(
                Filters.or(
                        Filters.eq("owner", "baldwin"),
                        Filters.eq("owner", "beomund")
                ),
                Filters.eq("title", "crusade")

        );
        assertEquals(expectedResult,
                toTest.parse(List.of("owner:baldwin", "owner:beomund", "title:crusade"), attributes));
    }