I am using the Java Liquibase API with some deployment scripts written in Groovy. The groovy scripts and all dependencies are packaged together into a fat jar.
For some reason when we run this jar we get some weird errors. These do not block anything from happening. Everything works but we have tons of errors in the log where it looks like Liquibase is attempting to load the various groovy classes. We see multiple of the following error for each groovy class:
[java] SEVERE 7/16/14 12:32 PM: liquibase: Cannot load class 'bounce.class' in classloader: sun.misc.Launcher$AppClassLoader@4af6ae1c. Reason: java.lang.NullPointerException
12:32:07 [java] java.lang.NullPointerException
12:32:07 [java] at liquibase.servicelocator.DefaultPackageScanClassResolver.loadClass(DefaultPackageScanClassResolver.java:337)
12:32:07 [java] at liquibase.servicelocator.DefaultPackageScanClassResolver.loadImplementationsInJar(DefaultPackageScanClassResolver.java:387)
12:32:07 [java] at liquibase.servicelocator.DefaultPackageScanClassResolver.findAllClasses(DefaultPackageScanClassResolver.java:226)
12:32:07 [java] at liquibase.servicelocator.DefaultPackageScanClassResolver.find(DefaultPackageScanClassResolver.java:116)
12:32:07 [java] at liquibase.servicelocator.DefaultPackageScanClassResolver.findImplementations(DefaultPackageScanClassResolver.java:84)
12:32:07 [java] at liquibase.servicelocator.ServiceLocator.findClassesImpl(ServiceLocator.java:202)
12:32:07 [java] at liquibase.servicelocator.ServiceLocator.findClasses(ServiceLocator.java:177)
12:32:07 [java] at liquibase.changelog.ChangeLogHistoryServiceFactory.<init>(ChangeLogHistoryServiceFactory.java:40)
12:32:07 [java] at liquibase.changelog.ChangeLogHistoryServiceFactory.getInstance(ChangeLogHistoryServiceFactory.java:20)
12:32:07 [java] at liquibase.changelog.ChangeLogHistoryServiceFactory$getInstance.call(Unknown Source)
12:32:07 [java] at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42)
12:32:07 [java] at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
12:32:07 [java] at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:112)
12:32:07 [java] at com.derp.LiquidbaseRunner.hasliquibaseTables(LiquidBaseRunner.groovy:46)
For some reason when we run this jar we get some weird errors. These do not block anything from happening. Everything works but we have tons of errors in the log where it looks like Liquibase is attempting to load the various groovy classes. We see multiple of the following error for each groovy class:
[java] SEVERE 7/16/14 12:32 PM: liquibase: Cannot load class 'bounce.class' in classloader: sun.misc.Launcher$AppClassLoader@4af6ae1c. Reason: java.lang.NullPointerException
12:32:07 [java] java.lang.NullPointerException
12:32:07 [java] at liquibase.servicelocator.DefaultPackageScanClassResolver.loadClass(DefaultPackageScanClassResolver.java:337)
12:32:07 [java] at liquibase.servicelocator.DefaultPackageScanClassResolver.loadImplementationsInJar(DefaultPackageScanClassResolver.java:387)
12:32:07 [java] at liquibase.servicelocator.DefaultPackageScanClassResolver.findAllClasses(DefaultPackageScanClassResolver.java:226)
12:32:07 [java] at liquibase.servicelocator.DefaultPackageScanClassResolver.find(DefaultPackageScanClassResolver.java:116)
12:32:07 [java] at liquibase.servicelocator.DefaultPackageScanClassResolver.findImplementations(DefaultPackageScanClassResolver.java:84)
12:32:07 [java] at liquibase.servicelocator.ServiceLocator.findClassesImpl(ServiceLocator.java:202)
12:32:07 [java] at liquibase.servicelocator.ServiceLocator.findClasses(ServiceLocator.java:177)
12:32:07 [java] at liquibase.changelog.ChangeLogHistoryServiceFactory.<init>(ChangeLogHistoryServiceFactory.java:40)
12:32:07 [java] at liquibase.changelog.ChangeLogHistoryServiceFactory.getInstance(ChangeLogHistoryServiceFactory.java:20)
12:32:07 [java] at liquibase.changelog.ChangeLogHistoryServiceFactory$getInstance.call(Unknown Source)
12:32:07 [java] at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:42)
12:32:07 [java] at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:108)
12:32:07 [java] at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:112)
12:32:07 [java] at com.derp.LiquidbaseRunner.hasliquibaseTables(LiquidBaseRunner.groovy:46)