In Mongo queries, it is very common to set a filter with "$in": [ some long array ] to avoid N+1 queries. Here's how this looks in the breadcrumb:
This is a problem because:
Its a ton of text
It's difficult to know how many members the array actually has.
Design
To fix this, in the Mongo filter field, an Array which (a) has more than 3 members and (b) does not contain nested Arrays or Hashes will be summarized as ["LENGTH=42"] (e.g. if it has 42 members)
Goal
In Mongo queries, it is very common to set a
filter
with"$in": [ some long array ]
to avoid N+1 queries. Here's how this looks in the breadcrumb:This is a problem because:
Design
To fix this, in the Mongo
filter
field, an Array which (a) has more than 3 members and (b) does not contain nested Arrays or Hashes will be summarized as["LENGTH=42"]
(e.g. if it has 42 members)Changeset
Only changes the Mongo breadcrumb functionality.
This also includes the changes from:
Testing
Tested in RSpec and by TableCheck in production.