25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

56 lines
2.0 KiB

  1. %% Ignore Msg Hole Name
  2. -define(eTpfHole, '$eTpfHole').
  3. %% 消息截取默认配置项
  4. -define(defTcmMap, #{
  5. tcmIsCut => false
  6. , tcmDepth => 5
  7. , tcmListSize => 32
  8. , tcmMapSize => 32
  9. , tcmTupleSize => 32
  10. , tcmBinSize => 128
  11. , tcmBitSize => 128 * 8
  12. , tcmNestStruct => 6
  13. }).
  14. -define(defPoolId, defPoolId).
  15. %% 类型声明
  16. -export_type([input/0, userInput/0, traceOpts/0, tracerOpts/0]).
  17. -type pattern() :: module() | {app, atom()} | {callback, module(), atom()}.
  18. -type scope() :: {scope, [pid() | port() | all | processes | ports |existing | existing_processes | existing_ports |new | new_processes | new_ports]}.
  19. -type input() :: [pattern() | scope()].
  20. -type userInput() :: pattern() | input().
  21. -type traceOpts() :: #{
  22. mode => trace | profile
  23. , poolId => any()
  24. , poolSize => pos_integer()
  25. , send => boolean()
  26. , running => boolean()
  27. , process_dump => boolean() %% 必需的trace选项 为了生成火焰图,我们目前在跟踪时需要使用一个附加选项。此选项将导致将堆栈跟踪信息添加到调用事件。选项为`process_dump`, 并且必须将其设置为`true`。
  28. }.
  29. -type tracerOpts() :: #{
  30. %% tracer for socket
  31. port => pos_integer()
  32. %% tracer for file
  33. , fBaseName => string()
  34. , fMaxSize => pos_integer()
  35. , fEventFrame => pos_integer()
  36. %% tracer for console
  37. %% trace msg term cut cfg
  38. , tcmIsCut => boolean() %% 是否cut trace msg term
  39. , tcmDepth => pos_integer() %% term cut时保留的最大深度
  40. , tcmListSize => pos_integer() %% List term cut时保留的最大数量
  41. , tcmMapSize => pos_integer() %% Map term cut时保留的最大数量
  42. , tcmTupleSize => pos_integer() %% Tuple term cut时保留的最大数量
  43. , tcmBinSize => pos_integer() %% Bin term cut时保留的最大字节数
  44. , tcmBitSize => pos_integer() %% Bits term cut时保留的最大bit数
  45. , tcmNestStruct => pos_integer() %% 复合结构 term cut时保留的最大数量
  46. }.