我正在使用Java Liquibase API和一些用Groovy编写的部署脚本。 groovy脚本和所有依赖项一起打包成一个胖罐。
出于某种原因,当我们运行这个jar时,我们会遇到一些奇怪的错误。这些不会阻止任何事情发生。一切正常但我们在日志中有很多错误,看起来Liquibase正在尝试加载各种groovy类。我们在每个groovy类中看到以下错误的多个:
[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)
答案 0 :(得分:1)
3.2.1版本今天或周一发布,改进了脂肪罐支持。我相信这会解决你的问题。