Skip to content

Commit

Permalink
fix extensions doc
Browse files Browse the repository at this point in the history
  • Loading branch information
m.kindritskiy committed Sep 16, 2024
1 parent fd2e523 commit f9ebe66
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions docs/extensions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,9 @@ and implement methods that you need.

.. note::

**Extension** class accepts **execution_context** argument, but it is optional.

You can pass either instance or a class of the Extension to the schema's `extensions` argument.

At runtime, if extension is a class, it will be instantiated with the **execution_context** argument.
If extension is an instance, **execution_context** argument will be set.
At runtime, if extension is a class, it will be instantiated by hiku.


Here is an example of custom extension that measures query execution time:
Expand Down Expand Up @@ -106,11 +103,6 @@ Query with separated variables is good for caching.
Gauge('hiku_query_cache_hits', 'Query cache hits')
Gauge('hiku_query_cache_misses', 'Query cache misses')
QueryTransformCache
~~~~~~~~~~~~~~~~~~~

Just like ``QueryParseCache``, ``QueryTransformCache`` caches the result of transformation from graphql ast into query :py:class:`hiku.query.Node`.

QueryValidationCache
~~~~~~~~~~~~~~~~~~~~

Expand Down

0 comments on commit f9ebe66

Please sign in to comment.