We are using Spring MappingJackson2HttpMessageConverter to convert our data to json resources.
We have noticed that if the record id is a large number such as eg:1234567891234567891 the converted resource id (record id is the resource id) is automatically rounded up to 1234567891234568000.
It seems the Jackson can't handle the larger number or is it some limitation in javascript/json number representations?
Following is our current MappingJackson2HttpMessageConverter configurations
Jackson2ObjectMapperBuilder builder = new Jackson2ObjectMapperBuilder();
DateFormat defaultResourceDateOutputFormat = new SimpleDateFormat(
DEFAULT_INTERNAL_DATE_FORMAT);
builder.dateFormat(defaultResourceDateOutputFormat);
builder.timeZone(TimeZone.getDefault());
builder.serializationInclusion(Include.NON_NULL);
builder.featuresToDisable(
DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES);
builder.defaultViewInclusion(Boolean.TRUE);
I have referred Large numbers erroneously rounded in Javascript but not sure it's caused by the same reason.
Appreciate any feedback. Thanks in advance