Skip to main content
The HarmonyOS SDK assembles RUM data as NDJSON batches and uploads them to Flashduty. The current version collects four RUM event types: view, action, resource, and error. Crashes and hangs enter the same pipeline as error events with is_crash.

Default context

After initialization, the SDK attaches shared context to every event.
clientToken is only used for report authentication and is never attached to RUM events.

Session rules

The SDK manages sampling and lifecycle at the session level.

View events

A view represents a page or business screen. Generate views through automatic route tracking or manual APIs.
View events include:

Action events

An action represents user interaction. Record instantaneous actions with addAction(), or timed actions with startAction() and stopAction().
Supported action types: Action events include action.id, action.type, action.target.name, and action.loading_time. Actions recorded through FlashcatRum.trackTap() use type tap.

Resource events

A resource represents a network request. The SDK generates resources in these cases:
  • You use an rcp session with FlashcatTrace.interceptor()
  • You use FlashcatHttp.request() to wrap @kit.NetworkKit requests
  • You manually call GlobalRumMonitor.get().startResource() and stopResource()
Resource events include: Automatic network collection maps resource types as follows: If the request fails, the SDK generates an error event with source: "network" and includes method, status code, and URL in error.resource.

Error events

Errors represent manually reported errors, unhandled ArkTS exceptions, network errors, crashes, or hangs.
Supported error sources: Error events include:

Crashes and hangs

The Crash module listens to HarmonyOS hiAppEvent for APP_CRASH and APP_FREEZE. The system persists faults and replays them on the next launch, so enable the Crash module early in startup. Crash events are reported through the RUM error pipeline:
  • ArkTS / JS stacks are parsed as V8-style frames
  • Native C/C++ stacks are parsed in #NN pc <address> <lib.so> form
  • If you upload sourceMaps.map, nameCache.json, and unstripped .so files, the server resolves source files, function names, lines, columns, and native symbols

Upload behavior

The SDK uploads events as NDJSON batches.

Currently not collected

The current HarmonyOS SDK does not automatically collect:
  • Session Replay
  • Web Vitals or browser page performance metrics
  • HarmonyOS page rendering performance metrics
  • Automatic frustration events
  • Network connectivity changes; connectivity.status currently remains unknown