This commit adds the required infrastructure for instrumenting the
GraphQL engine and datafetchers in order to collect metrics.
With this infrastructure, we can collect metrics such as:
* "graphql.request", a timer for GraphQL query
* "graphql.datafetcher", a timer for GraphQL datafetcher calls
* "graphql.request.datafetch.count", a distribution summary of
datafetcher count per query
* "graphql.error", an error counter
See gh-29140
Previously the parameters were not ignored so */*;q=0.8 was not
identified as accepting */*. As a result, the most recent producible
content type was returned rather than the default.
This commit updates the argument resolver to ignore parameters.
The default content type is now produced in response to a request
that accepts */*, irrespective of its parameters.
Fixes gh-28446
Change the cache in `CachingOperationInvoker` to be a reference based
map and also clean stale entries when a specific threshold is met.
Fixes gh-28313
Update Prometheus `TextOutputFormat` so that OpenMetrics is used in
preference to text output when an appropriate accept header is found.
If the accept header contains `*/*` or is missing then the text format
will be used.
See gh-28130
Add an `isDefault()` method to `Producible` which can be used to
indicate which of the enum values should be used when the accept header
is `*/*` or `null`.
Prior to this commit, the last enum value was always used as the
default.
See gh-28130