Uploaded image for project: 'IMPALA'
  1. IMPALA
  2. IMPALA-4442

FE ParserTests may report UnsatisfiedLinkError

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: Impala 2.8.0
    • Fix Version/s: Impala 2.8.0
    • Component/s: Infrastructure
    • Labels:

      Description

      In some development environments, the ParserTests may always fail with an UnsatisfiedLinkError:

      java.lang.UnsatisfiedLinkError: org.apache.impala.service.FeSupport.NativeGetStartupOptions()[B
      	at org.apache.impala.service.FeSupport.NativeGetStartupOptions(Native Method)
      	at org.apache.impala.service.FeSupport.GetStartupOptions(FeSupport.java:268)
      	at org.apache.impala.common.RuntimeEnv.<init>(RuntimeEnv.java:47)
      	at org.apache.impala.common.RuntimeEnv.<clinit>(RuntimeEnv.java:34)
      	at org.apache.impala.testutil.TestUtils.assumeKuduIsSupported(TestUtils.java:288)
      	at org.apache.impala.analysis.ParserTest.TestKuduUpdate(ParserTest.java:1697)
      

      Lars Volker reported seeing this last month, while no others saw this. As of this morning, I started to experience the same issue.

      I believe the issue is related to some static loading of classes and/or libraries in Java because changing the ParserTest to initialize the Frontend makes the error go away. I haven't been able to pin-point the exact issue with loading, but it makes sense that the ParserTest should initialize the Frontend static state if it will be called by libfesupport later since it seems to be an issue affecting some environments and not others, i.e. subject to environmental factors.

        Activity

        Hide
        bharathv bharath v added a comment -

        https://gerrit.cloudera.org/#/c/4867 removes the libfesupport.so dependency on RuntimeEnv. So its likely we don't hit this anymore.

        Show
        bharathv bharath v added a comment - https://gerrit.cloudera.org/#/c/4867 removes the libfesupport.so dependency on RuntimeEnv. So its likely we don't hit this anymore.
        Hide
        mjacobs Matthew Jacobs added a comment -

        commit 1a99b78227dc37e2ab10d8b117fbc6930b703efb
        Author: Matthew Jacobs <mj@cloudera.com>
        Date: Mon Nov 7 11:50:24 2016 -0800

        IMPALA-4442: Fix FE ParserTests UnsatisfiedLinkError

        In some development environments, the ParserTests may always fail with an
        java.lang.UnsatisfiedLinkError:

        org.apache.impala.service.FeSupport.NativeGetStartupOptions()[B
        at o.a.i.service.FeSupport.NativeGetStartupOptions(Native Method)
        at o.a.i.service.FeSupport.GetStartupOptions(FeSupport.java:268)
        at o.a.i.common.RuntimeEnv.<init>(RuntimeEnv.java:47)
        at o.a.i.common.RuntimeEnv.<clinit>(RuntimeEnv.java:34)
        at o.a.i.testutil.TestUtils.assumeKuduIsSupported(TestUtils.java:288)
        at o.a.i.analysis.ParserTest.TestKuduUpdate(ParserTest.java:1697)

        I believe the issue is related to some static loading of
        classes and/or libraries in Java because changing the
        ParserTest to initialize the Frontend makes the error go
        away. I haven't been able to pin-point the exact issue with
        loading, but it makes sense that the ParserTest should
        initialize the Frontend static state if it will be called by
        libfesupport later since it seems to be an issue affecting
        some environments and not others, i.e. subject to
        environmental factors.

        This fixes the issue by changing ParserTest to extend
        FrontendTestBase which initializes the Frontend class
        statically.

        Change-Id: I1828504f79c51679f9ca07176bffbe248d450e87
        Reviewed-on: http://gerrit.cloudera.org:8080/4976
        Reviewed-by: Alex Behm <alex.behm@cloudera.com>
        Tested-by: Internal Jenkins

        Show
        mjacobs Matthew Jacobs added a comment - commit 1a99b78227dc37e2ab10d8b117fbc6930b703efb Author: Matthew Jacobs <mj@cloudera.com> Date: Mon Nov 7 11:50:24 2016 -0800 IMPALA-4442 : Fix FE ParserTests UnsatisfiedLinkError In some development environments, the ParserTests may always fail with an java.lang.UnsatisfiedLinkError: org.apache.impala.service.FeSupport.NativeGetStartupOptions()[B at o.a.i.service.FeSupport.NativeGetStartupOptions(Native Method) at o.a.i.service.FeSupport.GetStartupOptions(FeSupport.java:268) at o.a.i.common.RuntimeEnv.<init>(RuntimeEnv.java:47) at o.a.i.common.RuntimeEnv.<clinit>(RuntimeEnv.java:34) at o.a.i.testutil.TestUtils.assumeKuduIsSupported(TestUtils.java:288) at o.a.i.analysis.ParserTest.TestKuduUpdate(ParserTest.java:1697) I believe the issue is related to some static loading of classes and/or libraries in Java because changing the ParserTest to initialize the Frontend makes the error go away. I haven't been able to pin-point the exact issue with loading, but it makes sense that the ParserTest should initialize the Frontend static state if it will be called by libfesupport later since it seems to be an issue affecting some environments and not others, i.e. subject to environmental factors. This fixes the issue by changing ParserTest to extend FrontendTestBase which initializes the Frontend class statically. Change-Id: I1828504f79c51679f9ca07176bffbe248d450e87 Reviewed-on: http://gerrit.cloudera.org:8080/4976 Reviewed-by: Alex Behm <alex.behm@cloudera.com> Tested-by: Internal Jenkins

          People

          • Assignee:
            mjacobs Matthew Jacobs
            Reporter:
            mjacobs Matthew Jacobs
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development