Support Questions

Find answers, ask questions, and share your expertise

NiFi Cluster NullPointerException issue when restarting nodes

avatar
New Contributor

Hi,

 

I have a 3-node cluster with openjdk11. When I restarted the NiFi nodes, it had the following NullPointerException. However, if I update JAVA_HOME to Java8 for all nodes. The error couldn't be reproduced any more.

 

2021-01-21 15:31:40,540 ERROR [NiFi Web Server-54] o.a.nifi.web.api.config.ThrowableMapper An unexpected error has occurred: java.lang.RuntimeException: Failed to parse response as entity of type class org.apache.nifi.web.api.entity.FlowConfigurati
onEntity. Returning Internal Server Error response.
java.lang.RuntimeException: Failed to parse response as entity of type class org.apache.nifi.web.api.entity.FlowConfigurationEntity
.
.
.
Caused by: com.fasterxml.jackson.databind.JsonMappingException: Text '15:31:40 CST' could not be parsed: null (through reference chain: org.apache.nifi.web.api.entity.FlowConfigurationEntity["flowConfiguration"]->org.apache.nifi.web.api.dto.FlowConfigurationDTO["currentTime"])
        at com.fasterxml.jackson.databind.JsonMappingException.wrapWithPath(JsonMappingException.java:394)
        at com.fasterxml.jackson.databind.JsonMappingException.wrapWithPath(JsonMappingException.java:353)
        at com.fasterxml.jackson.databind.deser.BeanDeserializerBase.wrapAndThrow(BeanDeserializerBase.java:1711)
        at com.fasterxml.jackson.databind.deser.BeanDeserializer.vanillaDeserialize(BeanDeserializer.java:290)
        at com.fasterxml.jackson.databind.deser.BeanDeserializer.deserialize(BeanDeserializer.java:151)
        at com.fasterxml.jackson.databind.deser.impl.MethodProperty.deserializeAndSet(MethodProperty.java:129)
        at com.fasterxml.jackson.databind.deser.BeanDeserializer.vanillaDeserialize(BeanDeserializer.java:288)
        at com.fasterxml.jackson.databind.deser.BeanDeserializer.deserialize(BeanDeserializer.java:151)
        at com.fasterxml.jackson.databind.ObjectMapper._readValue(ObjectMapper.java:3985)
        at com.fasterxml.jackson.databind.ObjectMapper.readValue(ObjectMapper.java:2277)
        at com.fasterxml.jackson.core.JsonParser.readValueAs(JsonParser.java:1729)
        at org.apache.nifi.cluster.coordination.http.replication.okhttp.JacksonResponse.readEntity(JacksonResponse.java:101)
        ... 123 common frames omitted
Caused by: java.time.format.DateTimeParseException: Text '15:31:40 CST' could not be parsed: null
        at java.base/java.time.format.DateTimeFormatter.createError(DateTimeFormatter.java:2017)
        at java.base/java.time.format.DateTimeFormatter.parse(DateTimeFormatter.java:1952)
 
Does anyone happen to know the issue?
 
Thanks
 
3 REPLIES 3

avatar

The first thing to check is if your version of the platform supports your version of OpenJDK.

 

For instance, if you are on HDF 3.5 or below, then OpenJDK does not appear to be supported: https://supportmatrix.hortonworks.com/

 

However, if you are on the latest Flow Management version in CDP, then OpenJDK 11.0.8 and above should be fine, as per https://docs.cloudera.com/cfm/2.0.4/support-matrix/topics/cfm-system-requirements.html 

 

If you confirmed that you are within the right combination of platform and JDK version and the problem still persists I would recommend to log a support ticket (I did not find other occurances of this error).


- Dennis Jaheruddin

If this answer helped, please mark it as 'solved' and/or if it is valuable for future readers please apply 'kudos'.

avatar
New Contributor

Thanks for the reply. I don't think I used HDF. I just installed the nifi 1.12.1 binary into three physical machines. 

avatar
Master Mentor

@kk_nifi 

 

This is more likely an issue in the specific Java 11 version your are using.
https://bugs.openjdk.java.net/browse/JDK-8243541

Somethings you may want to try:
1. Try a different update version of Java 11
2. add the following line to the NiFi bootstrap.conf file:

java.arg.<some unused number>=-Djava.locale.providers=COMPAT

Note: A restart of NiFi is needed with any config file change except logback.xml.

Hope this helps,

Matt