OperationSpec

OperationSpec

Describes the interface for an operation function.

Properties:
Name Type Attributes Default Description
name string <optional>

The name for this operation. If omitted, the operation function's name will used instead.

parameters DatastoreParameters <optional>

Extra parameters to be set on the metric for the operation.

record bool <optional>
true

Indicates if the operation should be recorded as a metric. A segment will be created even if this is false.

callback number | CallbackBindFunction <optional>

If a number, it is the offset in the arguments array for the operation's callback argument. If it is a function, it should perform the segment binding to the callback.

promise bool <optional>
false

If true, the return value will be wrapped as a Promise.

Source:
See: