Skip to content

Commit ae034da

Browse files
committed
Realtime Pipeline Proto changes
1 parent 04deedf commit ae034da

File tree

3 files changed

+21
-0
lines changed

3 files changed

+21
-0
lines changed

firebase-firestore/src/proto/google/firebase/firestore/proto/target.proto

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,9 @@ message Target {
7777

7878
// A target specified by a set of document names.
7979
google.firestore.v1.Target.DocumentsTarget documents = 6;
80+
81+
// A target specified by a pipeline query.
82+
google.firestore.v1.Target.PipelineQueryTarget pipeline_query = 13;
8083
}
8184

8285
// Denotes the maximum snapshot version at which the associated query view

firebase-firestore/src/proto/google/firestore/v1/firestore.proto

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -866,13 +866,25 @@ message Target {
866866
}
867867
}
868868

869+
// A target specified by a pipeline query.
870+
message PipelineQueryTarget {
871+
// The pipeline to run.
872+
oneof pipeline_type {
873+
// A pipelined operation in structured format.
874+
StructuredPipeline structured_pipeline = 1;
875+
}
876+
}
877+
869878
// The type of target to listen to.
870879
oneof target_type {
871880
// A target specified by a query.
872881
QueryTarget query = 2;
873882

874883
// A target specified by a set of document names.
875884
DocumentsTarget documents = 3;
885+
886+
// A target specified by a pipeline query.
887+
PipelineQueryTarget pipeline_query = 13;
876888
}
877889

878890
// When to start listening.

firebase-firestore/src/proto/google/firestore/v1/write.proto

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,12 @@ message WriteResult {
200200
//
201201
// Multiple [DocumentChange][google.firestore.v1.DocumentChange] messages may be
202202
// returned for the same logical change, if multiple targets are affected.
203+
//
204+
// For PipelineQueryTargets, `document` will be in the new pipeline format,
205+
// (-- TODO(b/330735468): Insert link to spec. --)
206+
// For a Listen stream with both QueryTargets and PipelineQueryTargets present,
207+
// if a document matches both types of queries, then a separate DocumentChange
208+
// messages will be sent out one for each set.
203209
message DocumentChange {
204210
// The new state of the [Document][google.firestore.v1.Document].
205211
//

0 commit comments

Comments
 (0)