REPLICA_PREFERENCE Query Option (CDH 5.9 or higher only)
The REPLICA_PREFERENCE query option lets you distribute the work more evenly if hotspots and bottlenecks persist. It causes the access cost of all replicas of a data block to be considered equal to or worse than the configured value. This allows Impala to schedule reads to suboptimal replicas (e.g. local in the presence of cached ones) in order to distribute the work across more executor nodes.
Allowed values are: CACHE_LOCAL (0), DISK_LOCAL (2), REMOTE (4)
Default: CACHE_LOCAL (0)
Added in: CDH 5.9.0 / Impala 2.7.0
By default Impala selects the best replica it can find in terms of access cost. The preferred order is cached, local, and remote. With REPLICA_PREFERENCE, the preference of all replicas are capped at the selected value. For example, when REPLICA_PREFERENCE is set to DISK_LOCAL, cached and local replicas are treated with the equal preference. When set to REMOTE, all three types of replicas, cached, local, remote, are treated with equal preference.
Using HDFS Caching with Impala (CDH 5.3 or higher only), SCHEDULE_RANDOM_REPLICA Query Option (CDH 5.7 or higher only)