You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "Jeremy Dyer (JIRA)" <ji...@apache.org> on 2017/01/13 17:00:27 UTC
[jira] [Created] (NIFI-3343) Annotate
@XmlJavaTypeAdapter(DateTimeAdapter.class) fields in client dto with
JsonFormat
Jeremy Dyer created NIFI-3343:
---------------------------------
Summary: Annotate @XmlJavaTypeAdapter(DateTimeAdapter.class) fields in client dto with JsonFormat
Key: NIFI-3343
URL: https://issues.apache.org/jira/browse/NIFI-3343
Project: Apache NiFi
Issue Type: Improvement
Components: Core Framework
Affects Versions: 1.1.1
Reporter: Jeremy Dyer
Assignee: Jeremy Dyer
Fix For: 1.2.0
Currently when implementing a client to consume NiFi client dto serialized objects Jackson is unable to deserialize @XmlJavaTypeAdapter(DateTimeAdapter.class) to a Java Date object since the format is unknown. Simply setting the default ObjectMapper default date using something like ...
DateFormat dateFormat = new SimpleDateFormat("HH:mm:ss Z");
this.mapper.setDateFormat(dateFormat);
Will not work because there are portions that do have dates in this format. The only options seems to making the end users write their own custom date deserializers =( or annotating the dto object fields with @JsonFormat so that it is handled for them automatically.
I plan to annotate the fields because that seems most efficient for everyone.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)