@@ -155,7 +155,7 @@ function patchAddDoc<AppModelType, DbModelType extends DocumentData>(
155
155
reference : CollectionReference < AppModelType , DbModelType > ,
156
156
data : WithFieldValue < AppModelType > ,
157
157
) : Promise < DocumentReference < AppModelType , DbModelType > > {
158
- const span = startSpan ( tracer , 'addDoc' , reference ) ;
158
+ const span = startDBSpan ( tracer , 'addDoc' , reference ) ;
159
159
firestoreSpanCreationHook ( span ) ;
160
160
return executeContextWithSpan < Promise < DocumentReference < AppModelType , DbModelType > > > ( span , ( ) => {
161
161
return original ( reference , data ) ;
@@ -172,7 +172,7 @@ function patchDeleteDoc<AppModelType, DbModelType extends DocumentData>(
172
172
) => ( this : FirebaseInstrumentation , reference : DocumentReference < AppModelType , DbModelType > ) => Promise < void > {
173
173
return function deleteDoc ( original : DeleteDocType < AppModelType , DbModelType > ) {
174
174
return function patchDeleteDoc ( reference : DocumentReference < AppModelType , DbModelType > ) : Promise < void > {
175
- const span = startSpan ( tracer , 'deleteDoc' , reference . parent || reference ) ;
175
+ const span = startDBSpan ( tracer , 'deleteDoc' , reference . parent || reference ) ;
176
176
firestoreSpanCreationHook ( span ) ;
177
177
return executeContextWithSpan < Promise < void > > ( span , ( ) => {
178
178
return original ( reference ) ;
@@ -194,7 +194,7 @@ function patchGetDocs<AppModelType, DbModelType extends DocumentData>(
194
194
return function patchGetDocs (
195
195
reference : CollectionReference < AppModelType , DbModelType > ,
196
196
) : Promise < QuerySnapshot < AppModelType , DbModelType > > {
197
- const span = startSpan ( tracer , 'getDocs' , reference ) ;
197
+ const span = startDBSpan ( tracer , 'getDocs' , reference ) ;
198
198
firestoreSpanCreationHook ( span ) ;
199
199
return executeContextWithSpan < Promise < QuerySnapshot < AppModelType , DbModelType > > > ( span , ( ) => {
200
200
return original ( reference ) ;
@@ -220,7 +220,7 @@ function patchSetDoc<AppModelType, DbModelType extends DocumentData>(
220
220
data : WithFieldValue < AppModelType > & PartialWithFieldValue < AppModelType > ,
221
221
options ?: SetOptions ,
222
222
) : Promise < void > {
223
- const span = startSpan ( tracer , 'setDocs' , reference . parent || reference ) ;
223
+ const span = startDBSpan ( tracer , 'setDocs' , reference . parent || reference ) ;
224
224
firestoreSpanCreationHook ( span ) ;
225
225
226
226
return executeContextWithSpan < Promise < void > > ( span , ( ) => {
@@ -247,7 +247,7 @@ function executeContextWithSpan<T>(span: Span, callback: () => T): T {
247
247
} ) ;
248
248
}
249
249
250
- function startSpan < AppModelType , DbModelType extends DocumentData > (
250
+ function startDBSpan < AppModelType , DbModelType extends DocumentData > (
251
251
tracer : Tracer ,
252
252
spanName : string ,
253
253
reference : CollectionReference < AppModelType , DbModelType > | DocumentReference < AppModelType , DbModelType > ,
0 commit comments