68
68
import org .springframework .data .mongodb .core .aggregation .AggregationOperationContext ;
69
69
import org .springframework .data .mongodb .core .aggregation .AggregationOptions ;
70
70
import org .springframework .data .mongodb .core .aggregation .AggregationResults ;
71
- import org .springframework .data .mongodb .core .aggregation .TypeBasedAggregationOperationContext ;
72
71
import org .springframework .data .mongodb .core .aggregation .TypedAggregation ;
73
72
import org .springframework .data .mongodb .core .convert .DbRefResolver ;
74
73
import org .springframework .data .mongodb .core .convert .DefaultDbRefResolver ;
@@ -1900,10 +1899,7 @@ public <O> Stream<O> aggregateStream(TypedAggregation<?> aggregation, String inp
1900
1899
Class <O > outputType ) {
1901
1900
1902
1901
Assert .notNull (aggregation , "Aggregation pipeline must not be null" );
1903
-
1904
- AggregationOperationContext context = new TypeBasedAggregationOperationContext (aggregation .getInputType (),
1905
- mappingContext , queryMapper );
1906
- return aggregateStream (aggregation , inputCollectionName , outputType , context );
1902
+ return aggregateStream (aggregation , inputCollectionName , outputType , null );
1907
1903
}
1908
1904
1909
1905
@ Override
@@ -1915,7 +1911,7 @@ public <O> Stream<O> aggregateStream(TypedAggregation<?> aggregation, Class<O> o
1915
1911
public <O > Stream <O > aggregateStream (Aggregation aggregation , Class <?> inputType , Class <O > outputType ) {
1916
1912
1917
1913
return aggregateStream (aggregation , getCollectionName (inputType ), outputType ,
1918
- new TypeBasedAggregationOperationContext ( inputType , mappingContext , queryMapper ));
1914
+ queryOperations . createAggregation ( aggregation , inputType ). getAggregationOperationContext ( ));
1919
1915
}
1920
1916
1921
1917
@ Override
0 commit comments