Skip to content

Commit b09a561

Browse files
committed
Tweaks and grammar
1 parent 3b85c58 commit b09a561

2 files changed

Lines changed: 12 additions & 12 deletions

File tree

docs/execution.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Queries
77
To execute a query against a schema build a new ``GraphQL`` object with the appropriate arguments and then
88
call ``execute()``.
99

10-
The result of a query is an ``ExecutionResult`` which is the result data and/or a list of Errors.
10+
The result of a query is an ``ExecutionResult`` which is the query data and/or a list of errors.
1111

1212
.. code-block:: java
1313
@@ -30,10 +30,10 @@ The result of a query is an ``ExecutionResult`` which is the result data and/or
3030
More complex examples: [StarWars query tests](src/test/groovy/graphql/StarWarsQueryTest.groovy)
3131

3232
Each graphql field type has a `DataFetcher <src/main/java/graphql/schema/DataFetcher.java>`_ associated with it. Often you
33-
can rely on ```PropertyDataFetcher <src/main/java/graphql/schema/PropertyDataFetcher.java>`_` to examine Java objects to
33+
can rely on `PropertyDataFetcher <src/main/java/graphql/schema/PropertyDataFetcher.java>`_ to examine Java POJO objects to
3434
provide field values from them.
3535

36-
However you will need to wire in top level domain objects via your own custom data fetchers. This might involve making
36+
However you will need to wire in your top level domain objects via your own custom data fetchers. This might involve making
3737
a database call or contacting another system over HTTP.
3838

3939
graphql-java is not opinionated about how you get your domain data objects, that is very much your concern. It is also not
@@ -51,7 +51,7 @@ A data fetcher might look like this:
5151
};
5252
5353
Each ``DataFetcher`` is passed a ``graphql.schema.DataFetchingEnvironment`` object which contains what field is being fetched, what
54-
arguments are being supplied to the field and other information such as the field parent object, the query root object or the query
54+
arguments have been supplied to the field and other information such as the field's parent object, the query root object or the query
5555
context object.
5656

5757
In the above example, the execution will wait for the data fetcher to return before moving on. You can make execution of

docs/instrumentation.rst

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ Instrumentation
33

44

55
The ``graphql.execution.instrumentation.Instrumentation`` interface allows you to inject code that can observe the
6-
execution of a query and also change the runtime behaviour somewhat.
6+
execution of a query and also change the runtime behaviour.
77

8-
The primary use case for this to allow say performance monitoring and custom logging but it could be used for many purposes.
8+
The primary use case for this is to allow say performance monitoring and custom logging but it could be used for many different purposes.
99

1010
When you build the ```Graphql`` object you can specify what ``Instrumentation`` to use (if any).
1111

@@ -19,12 +19,12 @@ When you build the ```Graphql`` object you can specify what ``Instrumentation``
1919
Custom Instrumentation
2020
----------------------
2121

22-
An implementation of ``Instrumentation`` needs to implement the "step" methods that represent the execution of a graphql query.
22+
An implementation of ``Instrumentation`` needs to implement the "begin" step methods that represent the execution of a graphql query.
2323

2424
Each step must give back a non null ``graphql.execution.instrumentation.InstrumentationContext`` object which will be called back
25-
when the step completes, indicating that it succeeded or failed with a Throwable.
25+
when the step completes, and will be told that it succeeded or failed with a Throwable.
2626

27-
The following is a basic custom ``Instrumentation`` that times overall execution time and puts it into a stateful object.
27+
The following is a basic custom ``Instrumentation`` that measures overall execution time and puts it into a stateful object.
2828

2929
.. code-block:: java
3030
@@ -108,7 +108,7 @@ Chaining Instrumentation
108108
------------------------
109109

110110
You can combine multiple ``Instrumentation``s together using the ``graphql.execution.instrumentation.ChainedInstrumentation`` class which
111-
accepts a list of ``Instrumentation`` objects and called them in that defined order.
111+
accepts a list of ``Instrumentation`` objects and calls them in that defined order.
112112

113113
.. code-block:: java
114114
@@ -126,10 +126,10 @@ accepts a list of ``Instrumentation`` objects and called them in that defined or
126126
Apollo Tracing Instrumentation
127127
------------------------------
128128

129-
``graphql.execution.instrumentation.tracing.TracingInstrumentation`` is an implementation that creates tracing information
129+
``graphql.execution.instrumentation.tracing.TracingInstrumentation`` is an ``Instrumentation`` implementation that creates tracing information
130130
about the query that is being executed.
131131

132-
It follows the Apollo proposed tracing format defined at https://github.com/apollographql/apollo-tracing
132+
It follows the Apollo proposed tracing format defined at `https://github.com/apollographql/apollo-tracing <https://github.com/apollographql/apollo-tracing>`_
133133

134134
A detailed tracing map will be created and placed in the ``extensions`` section of the result.
135135

0 commit comments

Comments
 (0)