Impala Public Jenkins has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/18611 )
Change subject: IMPALA-11342: Fix class loading in Hive UDFs' constructors ...................................................................... IMPALA-11342: Fix class loading in Hive UDFs' constructors Loading new classes from the same jar in the constructor of UDFs did not work in the catalog because the URLClassLoader was closed too early. Extended the lifecycle of the class loader a bit to let the catalog finish all initialisation. Note that the instantiation of legacy Hive UDFs doesn't seem necessary in the catalog, we can get all relevant info from the class. Generic UDFs do need to be instantiated to be able to call initialize(). Testing: - added new classes to load in test UDFs and loaded these in constructor / initialize() - ran the Hive UDF ee tests Change-Id: If16e38b8fc3b2577a5d32104ea9e6948b9562e24 Reviewed-on: http://gerrit.cloudera.org:8080/18611 Reviewed-by: Impala Public Jenkins <[email protected]> Tested-by: Impala Public Jenkins <[email protected]> --- M fe/src/main/java/org/apache/impala/hive/executor/HiveJavaFunctionFactoryImpl.java M fe/src/main/java/org/apache/impala/hive/executor/HiveUdfLoader.java M fe/src/main/java/org/apache/impala/hive/executor/UdfExecutor.java M java/test-hive-udfs/src/main/java/org/apache/impala/GenericImportsNearbyClassesUdf.java M java/test-hive-udfs/src/main/java/org/apache/impala/ImportsNearbyClassesUdf.java A java/test-hive-udfs/src/main/java/org/apache/impala/UtilForUdfConstructor.java A java/test-hive-udfs/src/main/java/org/apache/impala/UtilForUdfInitialize.java 7 files changed, 87 insertions(+), 21 deletions(-) Approvals: Impala Public Jenkins: Looks good to me, approved; Verified -- To view, visit http://gerrit.cloudera.org:8080/18611 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: If16e38b8fc3b2577a5d32104ea9e6948b9562e24 Gerrit-Change-Number: 18611 Gerrit-PatchSet: 5 Gerrit-Owner: Csaba Ringhofer <[email protected]> Gerrit-Reviewer: Csaba Ringhofer <[email protected]> Gerrit-Reviewer: Daniel Becker <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Steve Carlin <[email protected]>
