Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Functions

createHook

  • Registers functions to be called for different lifetime events of each async operation.

    Parameters

    Returns AsyncHook

    an AsyncHooks instance used for disabling and enabling hooks

executionAsyncId

  • executionAsyncId(): number
  • Returns the asyncId of the current execution context.

    Returns number

executionAsyncResource

  • executionAsyncResource(): object
  • The resource representing the current execution. Useful to store data within the resource.

    Resource objects returned by executionAsyncResource() are most often internal Node.js handle objects with undocumented APIs. Using any functions or properties on the object is likely to crash your application and should be avoided.

    Using executionAsyncResource() in the top-level execution context will return an empty object as there is no handle or request object to use, but having an object representing the top-level can be helpful.

    Returns object

triggerAsyncId

  • triggerAsyncId(): number
  • Returns the ID of the resource responsible for calling the callback that is currently being executed.

    Returns number

Generated using TypeDoc