EntityFrameworkQueryableExtensions.TagWithCallSite<T> Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Adds a tag to the collection of tags associated with an EF LINQ query with source file name and line where method was called that can provide contextual tracing information at different points in the query pipeline.
public static System.Linq.IQueryable<T> TagWithCallSite<T> (this System.Linq.IQueryable<T> source, string? filePath = default, int lineNumber = 0);
static member TagWithCallSite : System.Linq.IQueryable<'T> * string * int -> System.Linq.IQueryable<'T>
<Extension()>
Public Function TagWithCallSite(Of T) (source As IQueryable(Of T), Optional filePath As String = Nothing, Optional lineNumber As Integer = 0) As IQueryable(Of T)
Type Parameters
- T
The type of entity being queried.
Parameters
- source
- IQueryable<T>
The source query.
- filePath
- String
The file name where the method was called
- lineNumber
- Int32
The file line number where the method was called
Returns
A new query annotated with the given tag.
Exceptions
source
Remarks
See Tagging queries in EF Core for more information and examples.
Applies to
Entity Framework