Options
All
  • Public
  • Public/Protected
  • All
Menu

External module "internal/util/memory"

Index

Variables

Let DataDirectory

DataDirectory: string = `${appRoot.path}/heap`

Functions

formatMillis

  • formatMillis(millis: number): string

gc

  • gc(): void

heapDump

  • heapDump(): string

initMemoryMonitoring

  • initMemoryMonitoring(dataDirectory?: string, log?: boolean): void
  • Initialise memory monitoring. This is will set the data directory for heap dumps and print the head usage to the connsole every 60 seconds.

    Parameters

    • Default value dataDirectory: string = `${appRoot.path}/heap`
    • Default value log: boolean = true

    Returns void

memoryUsage

  • memoryUsage(): object
  • Get some memory statistics.

    Returns object

    ; memory: {free: string; total: string}; up_time: string}}

    • up_time: string
    • heap: object
      • rss: string
      • total: string
      • used: string
    • memory: object
      • free: string
      • total: string

Generated using TypeDoc