11# Execution
22
3- GraphQL generates a response from a request via execution.
3+ GraphQL service generates a response from a request via execution.
44
55:: A _ request_ for execution consists of a few pieces of information:
66
@@ -144,8 +144,7 @@ executing the operation’s top level selection set on the mutation root object
144144type. This selection set should be executed serially.
145145
146146It is expected that the top level fields in a mutation operation perform
147- side-effects on the underlying data system. Serial execution of the provided
148- mutations ensures against race conditions during these side-effects.
147+ side-effects on the underlying data system.
149148
150149ExecuteMutation(mutation, schema, variableValues, initialValue):
151150
@@ -174,7 +173,7 @@ Subscribe(subscription, schema, variableValues, initialValue):
174173 {MapSourceToResponseEvent(sourceStream, subscription, schema, variableValues)}
175174- Return {responseStream}.
176175
177- Note: In large scale subscription systems , the {Subscribe()} and
176+ Note: In a large- scale subscription system , the {Subscribe()} and
178177{ExecuteSubscriptionEvent()} algorithms may be run on separate services to
179178maintain predictable scaling properties. See the section below on Supporting
180179Subscriptions at Scale.
@@ -222,7 +221,7 @@ must receive no more events from that event stream.
222221
223222** Supporting Subscriptions at Scale**
224223
225- Supporting subscriptions is a significant change for any GraphQL service. Query
224+ Supporting subscriptions is a significant challenge for a GraphQL service. Query
226225and mutation operations are stateless, allowing scaling via cloning of GraphQL
227226service instances. Subscriptions, by contrast, are stateful and require
228227maintaining the GraphQL document, variables, and other context over the lifetime
@@ -396,7 +395,7 @@ completion before it continues on to the next item in the grouped field set:
396395For example, given the following selection set to be executed serially:
397396
398397``` graphql example
399- {
398+ mutation {
400399 changeBirthday (birthday : $newBirthday ) {
401400 month
402401 }
@@ -418,7 +417,7 @@ As an illustrative example, let's assume we have a mutation field
418417we execute the following selection set serially:
419418
420419``` graphql example
421- {
420+ mutation {
422421 first : changeTheNumber (newNumber : 1 ) {
423422 theNumber
424423 }
0 commit comments