java.lang.NullPointerException (org.apache.commons.lang3)
See original GitHub issueAfter build Gaffer, executing my project with Java 8 Update 301 (64-bit), i’ve found this error:
Exception in thread "main" java.lang.NullPointerException: Cannot invoke "org.apache.commons.lang3.JavaVersion.atLeast(org.apache.commons.lang3.JavaVersion)" because "org.apache.commons.lang3.SystemUtils.JAVA_SPECIFICATION_VERSION_AS_ENUM" is null at org.apache.commons.lang3.SystemUtils.isJavaVersionAtLeast(SystemUtils.java:1413) at org.apache.commons.lang3.ClassUtils.isAssignable(ClassUtils.java:594) at org.apache.commons.lang3.reflect.TypeUtils.isAssignable(TypeUtils.java:376) at org.apache.commons.lang3.reflect.TypeUtils.getTypeArguments(TypeUtils.java:900) at org.apache.commons.lang3.reflect.TypeUtils.getTypeArguments(TypeUtils.java:798) at org.apache.commons.lang3.reflect.TypeUtils.getTypeArguments(TypeUtils.java:784) at uk.gov.gchq.koryphe.signature.Signature.createTypeArgsFor(Signature.java:180) at uk.gov.gchq.koryphe.signature.Signature.createSignatureFromTypeVariable(Signature.java:122) at uk.gov.gchq.koryphe.signature.Signature.getInputSignature(Signature.java:72) at uk.gov.gchq.gaffer.store.schema.SchemaElementDefinitionValidator.validateFunctionArgumentTypes(SchemaElementDefinitionValidator.java:141) at uk.gov.gchq.gaffer.store.schema.SchemaElementDefinitionValidator.validate(SchemaElementDefinitionValidator.java:62) at uk.gov.gchq.gaffer.store.schema.SchemaElementDefinition.validate(SchemaElementDefinition.java:123) at uk.gov.gchq.gaffer.store.schema.Schema.validate(Schema.java:218) at uk.gov.gchq.gaffer.store.Store.validateSchemas(Store.java:696) at uk.gov.gchq.gaffer.store.Store.initialise(Store.java:284) at uk.gov.gchq.gaffer.mapstore.MapStore.initialise(MapStore.java:87) at uk.gov.gchq.gaffer.mapstore.SingleUseMapStore.initialise(SingleUseMapStore.java:44) at uk.gov.gchq.gaffer.store.Store.createStore(Store.java:262) at uk.gov.gchq.gaffer.graph.Graph$Builder.updateStore(Graph.java:1082) at uk.gov.gchq.gaffer.graph.Graph$Builder.build(Graph.java:970)
I’ve already solved this by changing commons-lang3 version from 3.3.2 to 3.12.0 in the main pom.xml file. I’m telling you for your knowledge. Best regards.
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (3 by maintainers)
Top GitHub Comments
@unclassified02 Thanks for the heads up. Will be closing this issue as we are already tracking the feature to upgrade to Java 11: https://github.com/gchq/Gaffer/issues/2300. This is useful to know though that we will need to look at this dependency.
@t92549 i’m using Eclipse IDE Version 2021-06. I also confirm that I’m using JRE 16: thanks to your suggestion I found out that Eclipse have an embedded JRE, not displayed in “Apps & features”.