-
Notifications
You must be signed in to change notification settings - Fork 11
feat: request includeInactive for all entity id queries #719
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
filters: [new GraphQlEntityFilter(request.id, request.entityType)], | ||
// If querying for a single API, then always want to includeInactive | ||
includeInactive: request.entityType === ObservabilityEntityType.Api | ||
// If querying for a single API by ID, then always want to includeInactive |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@skjindal93 does this work for non-api entities? Just wondering if there was a reason it was limited before.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It does in my testing, buy maybe @skjindal93 can confirm. I was the one that put the original limitation in just because I was only working with APIs. It may have not been needed even then.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. includeInactive
works entity type agnostic. Can be used with any of the entity types
Codecov Report
@@ Coverage Diff @@
## main #719 +/- ##
=======================================
Coverage 85.15% 85.15%
=======================================
Files 784 784
Lines 16064 16064
Branches 1997 1997
=======================================
Hits 13680 13680
Misses 2351 2351
Partials 33 33
Continue to review full report at Codecov.
|
This comment has been minimized.
This comment has been minimized.
So the failing test reminds me - we probably don't want this flag on for things that use the entity query handler like fetching topology or interactions data - can we make it configurable defaulting to true? |
Description
All single entity queries by ID will set
includeInactive
to true.