jadams-tresys commented on a change in pull request #131: Added max/minValidYear tunable URL: https://github.com/apache/incubator-daffodil/pull/131#discussion_r230799154
########## File path: daffodil-lib/src/main/scala/org/apache/daffodil/api/DaffodilTunables.scala ########## @@ -138,7 +138,15 @@ case class DaffodilTunables( val maximumSimpleElementSizeInCharacters: Int = 1024 * 1024, val initialRegexMatchLimitInCharacters: Int = 64, - val maximumRegexMatchLengthInCharacters: Int = 1024 * 1024) + val maximumRegexMatchLengthInCharacters: Int = 1024 * 1024, + + /* Due to differences in the DFDL spec and ICU4J SimpleDateFormat, we must have SimpleDateFormat + * parse in lenient mode, which allows the year value to overflow with very large years + * into possibly negative years. These tunables simply make sure that value we get back + * from SimpleDateFormat are reasonable + */ + val minValidYear: Int = 0, + val maxValidYear: Int = 9999) Review comment: Yes, I believe the actual supported limit of the ICU library is 5828963-12-20T00:00:00. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services