Don't try to get the native code version in the transport client (elastic/x-pack-elasticsearch#600)
The native controller process won't be running Original commit: elastic/x-pack-elasticsearch@d848e86cd5
This commit is contained in:
parent
4b1ed5b453
commit
5233ab9831
|
@ -33,6 +33,8 @@ public class MachineLearningFeatureSet implements XPackFeatureSet {
|
||||||
this.enabled = XPackSettings.MACHINE_LEARNING_ENABLED.get(settings);
|
this.enabled = XPackSettings.MACHINE_LEARNING_ENABLED.get(settings);
|
||||||
this.licenseState = licenseState;
|
this.licenseState = licenseState;
|
||||||
Map<String, Object> nativeCodeInfo = NativeController.UNKNOWN_NATIVE_CODE_INFO;
|
Map<String, Object> nativeCodeInfo = NativeController.UNKNOWN_NATIVE_CODE_INFO;
|
||||||
|
// Don't try to get the native code version in the transport client - the controller process won't be running
|
||||||
|
if (XPackPlugin.transportClientMode(settings) == false) {
|
||||||
try {
|
try {
|
||||||
NativeController nativeController = NativeControllerHolder.getNativeController(settings);
|
NativeController nativeController = NativeControllerHolder.getNativeController(settings);
|
||||||
if (nativeController != null) {
|
if (nativeController != null) {
|
||||||
|
@ -45,6 +47,7 @@ public class MachineLearningFeatureSet implements XPackFeatureSet {
|
||||||
+ "- please check that you are running on a supported platform");
|
+ "- please check that you are running on a supported platform");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
this.nativeCodeInfo = nativeCodeInfo;
|
this.nativeCodeInfo = nativeCodeInfo;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue