V21.03: After pagination+cascade change, queries are too slow to finish

Hi Kenan,
In the query block a, can you please try the uid_in function and check if it improves performance.
Here is an example:

{
  devices as var(func: type(Device), first: 1000)  @filter(has(has_object)){
			h as has_object (first:10)
  }
    
  q(func: uid(devices)) @filter(uid_in(has_object,uid(h) )) {
    name
    count
    has_object   {
      name
      count
    }
  }
}

Please check if adding the has query also improves the overall performance.

1 Like