Device: Get Node issue if experence group has greater than 100 devices

I’m using a Device: Get Node in an experience workflow.

  • Using Query Method: “Experience Group ID”
  • not including connection status
  • not including attributes

All is good as long as the experience group does not have more than 100 devices.

If the experience group has more than 100 devices I get an error:
The error is: “experienceGroupId: Cannot resolve to more than 100 device query components”.

I initially had the"Result per Page" blank. I set it to 1000 and still got that error. I then tried setting it to 50 and still got the above error. With it set to 50 I even tried setting Page Number to 0 and still get same error.

The docs say: " Results Per Page: This templatable input is the maximum number of devices to return with one query. The max number of devices that can be returned at once is 1000. The default is 100."

OK I see. This is the problem where if the experience group has more than 100 children in it’s tree.
If I switch to a group with less than 100 children then it works.

I’m doing work on our older app. Our newer app works around this 100 limitation. I just forgot it was a limitation.

This error refers to the size of the query (query components) that gets built as the platform traverses the group hierarchy looking for matching devices.

For example, if you have a parent group with several child groups, when you ask for the devices for the parent, the platform traverses all children and compiles one large query. There is a limit of 100 components in this query.

This architecture allows for extremely dynamic device queries in your groups, but has the downside of generating huge queries whenever you ask for those devices. It’s a complicated tradeoff.

You are not the first person to run into this issue and we’ve been investigating alternative implementations for quite a while.

A workaround I do is that if a user is in the top-level group, I don’t use the user or group in the query since I can safely assume they have access to every device - I just query all devices. This bypasses the limit and provides a way to retrieve every device.