A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://docs.gitlab.com/development/graphql_guide/monitoring/ below:

Reading GraphQL logs | GitLab Docs

Help us learn about your current experience with the documentation.

Take the survey

.

Reading GraphQL logs

We use Kibana to filter GraphQL query logs. Sign in to Kibana with a @gitlab.com email address.

In Kibana we can inspect two kinds of GraphQL logs:

Logs of each GraphQL query

In a multiplex query, each individual query is logged separately. We can use subcomponent filtering to inspect these logs. Visit Kibana with this filter enabled or set up the subcomponent filter using these steps:

  1. Add a filter:
    1. Filter: json.subcomponent
    2. Operator: is
    3. Value: graphql_json
  2. Select Refresh.

You can select Kibana fields from the Available fields section of the sidebar to add columns to the log table, or visit this view, which already has a set of Kibana fields selected. Some relevant Kibana fields include:

Kibana field Description json.operation_name The operation name used by the client. json.operation_fingerprint The fingerprint of the query, used to recognize repeated queries over time. json.meta.caller_id Appears as graphql:<operation_name> for queries that came from the GitLab frontend, otherwise as graphql:unknown. Can be used to identify internal versus external queries. json.query_string The query string itself. json.is_mutation true when a mutation, false when not. json.query_analysis.used_fields List of GraphQL fields selected by the query. json.query_analysis.used_deprecated_fields List of deprecated GraphQL fields selected by the query. json.query_analysis.used_deprecated_arguments List of deprecated GraphQL arguments selected by the query. json.query_analysis.duration_s Duration of query execution in seconds. json.query_analysis.complexity The complexity score of the query. Useful filters

Below are some examples of common Kibana filters.

See field usage

See example of filter.

  1. Combine the subcomponent filter with the following Kibana filter:
    1. Filter: json.query_analysis.used_fields
    2. Operator: is
    3. Value: Type.myField, where Type.myField is the type name and field name as it appears in our GraphQL API resources documentation.
  2. Select Refresh.
See deprecated field usage

See example of filter.

  1. Combine the subcomponent filter with the following Kibana filter:
    1. Filter: json.query_analysis.used_deprecated_fields
    2. Operator: is
    3. Value: Type.myField, where Type.myField is the type name and field name as it appears in our GraphQL API resources documentation.
  2. Select Refresh.
See queries that were not made by our frontend

See example filter.

As mentioned above, json.meta.caller_id appears as graphql:<operation_name> for queries that came from the GitLab frontend, otherwise as graphql:unknown. This filter be used to identify internal versus external queries.

  1. Combine the subcomponent filter with the following Kibana filter:
    1. Filter: json.meta.caller_id
    2. Operator: is
    3. Value: graphql:unknown
  2. Select Refresh.
Logs of the full request

The full request logs encompass log data for all multiplexed queries in the request, as well as data from time spent outside of GraphQLController#execute.

To see the full request logs, do not apply the json.subcomponent filter, and instead:

  1. Add a filter:
    1. Filter: json.meta.caller_id
    2. Operator: is
    3. Value: GraphqlController#execute
  2. Select Refresh.

Some differences from the query logs described above:


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4