[
https://issues.apache.org/jira/browse/OLINGO-1009?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15478069#comment-15478069
]
Steven Hawkins commented on OLINGO-1009:
----------------------------------------
Only one more...
I think the issue you were seeing with unit tests without ids was due to always
adding/removing the ancestors:
{code}
boolean cycle = false;
if (expand != null && cycleDetected(ancestors, getEntityId(entity))) {
cycle = true;
} else {
if (ancestors == null) {
ancestors = new HashSet<String>();
}
ancestors.add(getEntityId(entity));
}
{code}
You don't need to do this unless expand is not null:
{code}
boolean cycle = false;
if (expand != null) {
if (ancestors == null) {
ancestors = new HashSet<String>();
}
cycle = !ancestors.add(getEntityId(entity)));
}
{code}
with a corresponding check in the finally/pop of the xml logic that checks for
the ancestor set.
> Provide serilization support for $levels with $expand
> -----------------------------------------------------
>
> Key: OLINGO-1009
> URL: https://issues.apache.org/jira/browse/OLINGO-1009
> Project: Olingo
> Issue Type: New Feature
> Components: odata4-server
> Affects Versions: (Java) V4 4.0.0-beta-01
> Reporter: Ramesh Reddy
> Assignee: Ramesh Reddy
> Fix For: (Java) V4 4.3.0
>
>
> Currently Olingo parses the query with $expand with $levels construct,
> however if the payload contains the nesting of the entities, it does not
> serialize to the defined $levels
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)