@@ -139,9 +139,9 @@ ExecuteQuery(query, schema, variableValues, initialValue):
139
139
- If {defers} is an empty map and {streams} is an empty list:
140
140
- Return an unordered map containing {data} and {errors}.
141
141
- Otherwise:
142
- - Let {responseStream} be a new event stream {responseStream} .
142
+ - Let {responseStream} be a new event stream.
143
143
- Call {IncrementalEventStream(responseStream, data, errors, defers, streams,
144
- variableValues)}.
144
+ variableValues)} asynchronously .
145
145
- Return {responseStream}.
146
146
147
147
IncrementalEventStream(responseStream, data, errors, initialDefers,
@@ -150,7 +150,6 @@ initialStreams, variableValues):
150
150
- Let {nextId} be {0}.
151
151
- Let {remainingDefers} be an empty set.
152
152
- Let {remainingStreams} be an empty set.
153
- - Let {hasNext} be {true}.
154
153
- Let {pending} be an empty list.
155
154
- If {initialDefers} is not an empty object:
156
155
- Let {id} be {nextId} and increment {nextId} by one.
@@ -171,13 +170,13 @@ initialStreams, variableValues):
171
170
- Let {pendingStream} be an unordered map containing {id}, {streamDetails}.
172
171
- Add {pendingStream} to {remainingStreams}.
173
172
- Let {initialResponse} be an unordered map containing {data}, {errors},
174
- {pending}, and {hasNext}.
173
+ {pending}, and the value {true} for key {hasNext}.
175
174
- Yield to {responseStream} the value {initialResponse}.
176
175
- Let {incremental} be an empty list.
177
176
- Let {errors} be an empty list.
178
177
- Let {pending} be an empty list.
179
178
- Let {completed} be an empty list.
180
- - When you {FlushStream(hasNext)}:
179
+ - Define the subprocedure {FlushStream(hasNext)} with the following actions :
181
180
- If {hasNext} is not provided, initialize it to {true}.
182
181
- Let {incrementalPayload} be an empty unordered map.
183
182
- Add {hasNext} to {incrementalPayload}.
0 commit comments