I’m running this query with 32 cats and 1 million urls takes 3 seconds, that looks excesive to the amount of data
countsbycat(func: eq(dgraph.type, "**cats**")) @filter(eq(catType, $catType) ) {
itemuid: uid
group: catType
label: label
itemsize_eq: count(~**url**.have_tier1 @filter( eq(url.language,"fr")) )
if I change edge reverse and groupby takes similar time
{
var (func: uid(0x2e8ee66)) {
~lang @groupby(url.have_tier1 ) {
a as count(uid)
}
}
cats(func: uid(a), orderdesc: val(a)) {
itemuid: uid
group: catType
label: label
itemsize: val(a)
}
}
infra: 3 zero, 3 alpha in HA/replicated data
Some idea to make this query faster?
Thanks