Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,20 @@ public static String tezAmComponentKey(String llapName) {

public static final String HIVE_LLAP_TASK_SCHEDULER_LOCALITY_DELAY_KEY = "hive.llap.task.scheduler.locality.delay";

/** Prefixes of the hive.* keys the Tez AM's LLAP plugins read from tez-site. */
private static final String[] TEZ_AM_PLUGIN_KEY_PREFIXES = {
"hive.llap.task.", "hive.llap.client.", "hive.llap.daemon.communicator."
};

public static boolean isTezAmPluginKey(String key) {
for (String prefix : TEZ_AM_PLUGIN_KEY_PREFIXES) {
if (key.startsWith(prefix)) {
return true;
}
}
return false;
}

public static final String METASTORE_SERVER_TRANSPORT_MODE_KEY = "metastore.server.thrift.transport.mode";
public static final String METASTORE_SERVER_TRANSPORT_MODE_DEFAULT = "http";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,17 @@ public static Map<String, String> getTezSite(HiveClusterSpec spec, LlapSpec llap
tezProps.put(ConfigUtils.HIVE_LLAP_DAEMON_UMBILICAL_PORT_KEY,
ConfigUtils.HIVE_LLAP_DAEMON_UMBILICAL_PORT_DEFAULT);

// A standalone AM's LLAP plugins -- task scheduler, task communicator, split location
// provider -- read tez-site, not hive-site. Users set these hive.llap keys in the
// HiveServer2 overrides, so copy them across; an explicit tezAm override below wins.
if (spec.hiveServer2().configOverrides() != null) {
spec.hiveServer2().configOverrides().forEach((key, value) -> {
if (ConfigUtils.isTezAmPluginKey(key)) {
tezProps.put(key, value);
}
});
}

if (spec.tezAm().configOverrides() != null) {
tezProps.putAll(spec.tezAm().configOverrides());
}
Expand Down
Loading