This is an automated email from the ASF dual-hosted git repository. davsclaus pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push: new c48851b CAMEL-17506 read query with key predicate returns one entity (#6781) c48851b is described below commit c48851b20687adeaf75ae9d8d1a063da43ee2c5b Author: damienb-opt <36661255+damienb-...@users.noreply.github.com> AuthorDate: Tue Jan 18 19:17:01 2022 +0100 CAMEL-17506 read query with key predicate returns one entity (#6781) https://issues.apache.org/jira/browse/CAMEL-17506 --- .../org/apache/camel/component/olingo4/api/impl/Olingo4AppImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/camel-olingo4/camel-olingo4-api/src/main/java/org/apache/camel/component/olingo4/api/impl/Olingo4AppImpl.java b/components/camel-olingo4/camel-olingo4-api/src/main/java/org/apache/camel/component/olingo4/api/impl/Olingo4AppImpl.java index b73f958..889f929 100644 --- a/components/camel-olingo4/camel-olingo4-api/src/main/java/org/apache/camel/component/olingo4/api/impl/Olingo4AppImpl.java +++ b/components/camel-olingo4/camel-olingo4-api/src/main/java/org/apache/camel/component/olingo4/api/impl/Olingo4AppImpl.java @@ -514,7 +514,7 @@ public final class Olingo4AppImpl implements Olingo4App { List<UriParameter> keyPredicates = uriResourceEntitySet.getKeyPredicates(); // Check result type: single Entity or EntitySet based // on key predicate detection - if (keyPredicates.size() == 1) { + if (keyPredicates.size() >= 1) { response = (T) odataReader.readEntity(content, getResourceContentType(uriInfo)); } else { response = (T) odataReader.readEntitySet(content, getResourceContentType(uriInfo));