Hey @milosgajdos, fancy bumping into you here!
I have reproduced your issue. However I see that in my version of Dgraph, things are correctly linked:
{
"data": {
"q": [
{
"uid": "0x2715",
"xid": "foo",
"name": "foo",
"links": [
{
"uid": "0x2716",
"links|relation": "Test",
"links|weight": 1
}
]
},
{
"uid": "0x2716",
"xid": "bar",
"name": "bar"
}
]
},
"extensions": {
"server_latency": {
"parsing_ns": 121906,
"processing_ns": 635903,
"encoding_ns": 164214,
"assign_timestamp_ns": 790831,
"total_ns": 1820709
},
"txn": {
"start_ts": 10060
},
"metrics": {
"num_uids": {
"_total": 9,
"links": 2,
"name": 2,
"uid": 3,
"xid": 2
}
}
}
}
I do note though that your query needs a bit of work. If you use the following, you would be able to get the facets data.
{
q(func: has(xid)) {
uid
xid
name
links @facets {uid}
}
}