Interface QueryPerformanceNugget.Factory

Enclosing class:
QueryPerformanceNugget

public static interface QueryPerformanceNugget.Factory
  • Method Details

    • createForQuery

      default QueryPerformanceNugget createForQuery(long evaluationNumber, @NotNull @NotNull String description, @Nullable @Nullable String sessionId, @NotNull @NotNull Consumer<QueryPerformanceNugget> onCloseCallback)
      Factory method for query-level nuggets.
      Parameters:
      evaluationNumber - A unique identifier for the query evaluation that triggered this nugget creation
      description - The operation description
      sessionId - The gRPC client session-id if applicable
      onCloseCallback - A callback that is invoked when the nugget is closed.
      Returns:
      A new nugget
    • createForSubQuery

      default QueryPerformanceNugget createForSubQuery(@NotNull @NotNull QueryPerformanceNugget parentQuery, long evaluationNumber, @NotNull @NotNull String description, @NotNull @NotNull Consumer<QueryPerformanceNugget> onCloseCallback)
      Factory method for sub-query-level nuggets.
      Parameters:
      parentQuery - The parent query nugget
      evaluationNumber - A unique identifier for the sub-query evaluation that triggered this nugget creation
      description - The operation description
      onCloseCallback - A callback that is invoked when the nugget is closed.
      Returns:
      A new nugget
    • createForOperation

      default QueryPerformanceNugget createForOperation(@NotNull @NotNull QueryPerformanceNugget parentQueryOrOperation, int operationNumber, String description, long inputSize, @NotNull @NotNull Consumer<QueryPerformanceNugget> onCloseCallback)
      Factory method for operation-level nuggets.
      Parameters:
      parentQueryOrOperation - The parent query / operation nugget
      operationNumber - A query-unique identifier for the operation
      description - The operation description
      onCloseCallback - A callback that is invoked when the nugget is closed.
      Returns:
      A new nugget
    • createForCompilation

      default QueryPerformanceNugget createForCompilation(@NotNull @NotNull QueryPerformanceNugget parentQueryOrOperation, int operationNumber, String description, @NotNull @NotNull Consumer<QueryPerformanceNugget> onCloseCallback)
      Factory method for compilation-level nuggets.
      Parameters:
      parentQueryOrOperation - The parent query / operation nugget
      operationNumber - A query-unique identifier for the operation
      description - The compilation description
      onCloseCallback - A callback that is invoked when the nugget is closed.
      Returns:
      A new nugget
    • createForCatchAll

      default QueryPerformanceNugget createForCatchAll(@NotNull @NotNull QueryPerformanceNugget parentQuery, int operationNumber, @NotNull @NotNull Consumer<QueryPerformanceNugget> onCloseCallback)
      Factory method for catch-all nuggets.
      Parameters:
      parentQuery - The parent query nugget
      operationNumber - A query-unique identifier for the operation
      onCloseCallback - A callback that is invoked when the nugget is closed.
      Returns:
      A new nugget