Components > Shared sequences > Number of reserved values
  

Number of reserved values

The number of reserved values determines the number of values in the sequence that the mapping task caches at one time during each task run.
When multiple Sequence transformations use the same shared sequence, multiple instances of the shared sequence can exist at the same time. To avoid generating duplicate values, reserve a range of sequence values for each mapping by configuring the number of reserved values.
For example, you configure a shared sequence as follows: Number of Reserved Values = 1000, Initial Value = 1, Increment By = 1. Two mappings use the shared sequence. When the first mapping task runs, Data Integration reserves 1000 values (1-1000) for the mapping task and updates the current value in the repository to 1001. When the second mapping task runs, Data Integration reserves the next 1000 values (1001-2000) and updates the current value to 2001. When either mapping task uses all of its reserved values, Data Integration reserves a new set of values and updates the current value.
The number of values that Data Integration reserves in a sequence is determined by multiplying the Number of Reserved Values by the Increment By value.
For example, if you have a shared sequence that begins at 2, increments by 2 and the number of reserved values is 1000, Data Integration reserves 1000 values in the sequence, or numerical values 2-2002, and updates the current value to 2003.
By default, the number of reserved values is 1000. To increase performance, you can increase the number of reserved values. This reduces the number of calls that Data Integration must make to the repository. The number of reserved values cannot be less than 1000.
Values that are reserved for a task run but not used in the task are lost when the task completes. For example, you generate IDs in a table with 1250 rows. You configure the shared sequence to generate values in increments of 1 and set the number of reserved values to 2000. When the task runs, Data Integration reserves 2000 values for the task and updates the current value to 2001. When the next task runs, the sequence begins at 2001, and values 1251-2000 are lost.
Note: If you use partitions, Data Integration reserves a set of values for each partition.