Class ClassListExtractor

  • All Implemented Interfaces:
    AutoCloseable

    public class ClassListExtractor
    extends Object
    implements AutoCloseable
    This class captures the classes loaded by the JVM of a UDF.
    • Constructor Detail

      • ClassListExtractor

        public ClassListExtractor​(com.exasol.bucketfs.Bucket bucket,
                                  LocalServiceExposer serviceExposer)
        Create a new instance of ClassListExtractor.
        Parameters:
        bucket - bucket for uploading an agent used for extracting the class list
        serviceExposer - callback that makes a local TCP service available inside the database
    • Method Detail

      • getJvmOptions

        public String[] getJvmOptions()
        Get the JVM options that must be added to the script.
        Returns:
        jvm options
      • capture

        public List<String> capture​(ClassListExtractor.CallbackWithQueryToScript runnable)
        Capture the class list of a UDF call.

        The query you want to analyze must involve a script that contains the JVM options provided by getJvmOptions(). To make sure that you don't forget this, this method will throw an exception if you did not call getJvmOptions() before this method.

        Parameters:
        runnable - function that performs the UDF call
        Returns:
        list of captured classes