Then, on the repository side, trying to fetch an application and its technologies would return the application but with an empty set of technologies:
@Query("MATCH (a:Application)" +
" OPTIONAL MATCH (a)-[r:RELIES_ON]->(t:Technology)" +
" RETURN a, r, t")
It can be fixed this by using COLLECT(r), COLLECT(t). Fetching and collecting the relationship part (even though it is not mapped to an @RelationshipProperties class) is important ; the list is empty with only COLLECT(t) even though that's what matters here.
Also, it looks like the behavior changed even for 1:1 mapping in this version (e.g. this ticket on SO).
I don't know if it is expected or not but maybe the documentation could be improve at this level as there seems to be behavioral differences between the previous SDN/OGM and SDN 6 regarding relationships.
You are right in both cases @robin850: You need to make use of the COLLECT function in order to provide a single result in contrast to a cartesian product. And yes, this is for sure some documentation missing on this bit. There is already an issue for this, so I will close this issue as it now is only a duplicate of #2032