@PublicApi public class TracingInstrumentation extends SimplePerformantInstrumentation
Instrumentation
implementation uses TracingSupport
to
capture tracing information and puts it into the ExecutionResult
Modifier and Type | Class and Description |
---|---|
static class |
TracingInstrumentation.Options |
INSTANCE
Constructor and Description |
---|
TracingInstrumentation() |
TracingInstrumentation(TracingInstrumentation.Options options) |
Modifier and Type | Method and Description |
---|---|
InstrumentationContext<java.lang.Object> |
beginFieldFetch(InstrumentationFieldFetchParameters parameters,
InstrumentationState rawState)
This is called just before a field
DataFetcher is invoked. |
InstrumentationContext<Document> |
beginParse(InstrumentationExecutionParameters parameters,
InstrumentationState rawState)
This is called just before a query is parsed.
|
InstrumentationContext<java.util.List<ValidationError>> |
beginValidation(InstrumentationValidationParameters parameters,
InstrumentationState rawState)
This is called just before the parsed query document is validated.
|
@Nullable InstrumentationState |
createState(InstrumentationCreateStateParameters parameters)
This will be called just before execution to create an object that is given back to all instrumentation methods
to allow them to have per execution request state
|
@NotNull java.util.concurrent.CompletableFuture<ExecutionResult> |
instrumentExecutionResult(ExecutionResult executionResult,
InstrumentationExecutionParameters parameters,
InstrumentationState rawState)
This is called to allow instrumentation to instrument the execution result in some way
|
beginExecuteOperation, beginExecuteOperation, beginExecution, beginExecution, beginExecutionStrategy, beginExecutionStrategy, beginField, beginField, beginFieldComplete, beginFieldComplete, beginFieldFetch, beginFieldListComplete, beginFieldListComplete, beginParse, beginSubscribedFieldEvent, beginSubscribedFieldEvent, beginValidation, createState, instrumentDataFetcher, instrumentDataFetcher, instrumentDocumentAndVariables, instrumentDocumentAndVariables, instrumentExecutionContext, instrumentExecutionContext, instrumentExecutionInput, instrumentExecutionInput, instrumentExecutionResult, instrumentSchema, instrumentSchema
public TracingInstrumentation()
public TracingInstrumentation(TracingInstrumentation.Options options)
@Nullable public @Nullable InstrumentationState createState(InstrumentationCreateStateParameters parameters)
Instrumentation
createState
in interface Instrumentation
createState
in class SimplePerformantInstrumentation
parameters
- the parameters to this step@NotNull public @NotNull java.util.concurrent.CompletableFuture<ExecutionResult> instrumentExecutionResult(ExecutionResult executionResult, InstrumentationExecutionParameters parameters, InstrumentationState rawState)
Instrumentation
instrumentExecutionResult
in interface Instrumentation
instrumentExecutionResult
in class SimplePerformantInstrumentation
executionResult
- CompletableFuture
of the result to instrumentparameters
- the parameters to this steprawState
- the state created during the call to Instrumentation.createState(InstrumentationCreateStateParameters)
public InstrumentationContext<java.lang.Object> beginFieldFetch(InstrumentationFieldFetchParameters parameters, InstrumentationState rawState)
Instrumentation
DataFetcher
is invoked.beginFieldFetch
in interface Instrumentation
beginFieldFetch
in class SimplePerformantInstrumentation
parameters
- the parameters to this steprawState
- the state created during the call to Instrumentation.createState(InstrumentationCreateStateParameters)
InstrumentationContext
object that will be called back when the step ends (assuming it's not null)public InstrumentationContext<Document> beginParse(InstrumentationExecutionParameters parameters, InstrumentationState rawState)
Instrumentation
beginParse
in interface Instrumentation
beginParse
in class SimplePerformantInstrumentation
parameters
- the parameters to this steprawState
- the state created during the call to Instrumentation.createState(InstrumentationCreateStateParameters)
InstrumentationContext
object that will be called back when the step ends (assuming it's not null)public InstrumentationContext<java.util.List<ValidationError>> beginValidation(InstrumentationValidationParameters parameters, InstrumentationState rawState)
Instrumentation
beginValidation
in interface Instrumentation
beginValidation
in class SimplePerformantInstrumentation
parameters
- the parameters to this steprawState
- the state created during the call to Instrumentation.createState(InstrumentationCreateStateParameters)
InstrumentationContext
object that will be called back when the step ends (assuming it's not null)