Class: ExecutionProfile

ExecutionProfile

Represents a set of configurations to be used in a statement execution to be used for a single DseClient instance.

A ExecutionProfile instance should not be shared across different DseClient instances.

Constructor

new ExecutionProfile(name, optionsopt)

Creates a new instance of ExecutionProfile.
Parameters:
Name Type Attributes Description
name String Name of the execution profile.

Use 'default' to specify that the new instance should be the default ExecutionProfile if no profile is specified in the execution.

options Object <optional>
Profile options, when any of the options is not specified the DseClient will the default profile
Properties
Name Type Attributes Description
consistency Number <optional>
The consistency level to use for this profile.
graphOptions Object <optional>
Properties
Name Type Attributes Description
name String <optional>
The graph name to use for graph queries.
readConsistency Number <optional>
The consistency level to use for graph read queries.
source String <optional>
The graph traversal source name to use for graph queries.
writeConsistency Number <optional>
The consistency level to use for graph write queries.
loadBalancing LoadBalancingPolicy <optional>
The load-balancing policy to use for this profile.
readTimeout Number <optional>
The client per-host request timeout to use for this profile.
retry RetryPolicy <optional>
The retry policy to use for this profile.
serialConsistency Number <optional>
The serial consistency level to use for this profile.
Example
const client = new dse.DseClient({
  contactPoints: ['host1', 'host2'],
  profiles: [
    new ExecutionProfile('metrics-oltp', {
      consistency: consistency.localQuorum,
      retry: myRetryPolicy
    })
  ]
});

client.execute(query, params, { executionProfile: 'metrics-oltp' }, callback);

Members

consistency :Number

Consistency level.
Type:
  • Number

graphOptions :Object

The graph options for this profile.
Type:
  • Object
Properties:
Name Type Description
name String The graph name.
readConsistency String The consistency to use for graph write queries.
source String The graph traversal source.
writeConsistency String The consistency to use for graph write queries.

loadBalancing :LoadBalancingPolicy

Load-balancing policy.
Type:
  • LoadBalancingPolicy

name :String

Name of the execution profile.
Type:
  • String

readTimeout :Number

Client per host read timeout.
Type:
  • Number

retry :RetryPolicy

Retry policy.
Type:
  • RetryPolicy

serialConsistency :Number

Serial consistency level.
Type:
  • Number