From: Mike M. <mi...@th...> - 2017-10-18 23:26:27
|
Hi, we have had an interface in production fail when we try to create a new message and call .initQuickstart(). What is happening is the id_file is read and the value is coerced into a number. Unfortunately the code uses an Int (10 chars long, max value 2147483647) so once the value in the id_file is increased beyond that limit this error occurs. Is this a known limitation with using initQuickstart? We have fixed it by resetting the value in the id_file to 1 (not ideal as it no longer guarantees uniqueness) As the MSH-10 is a string up to 20 chars surely this would work with Long values (19 chars max value: 9223372036854775807)? To replicate this issue create an id_file in your working dir with value: 2147483600 Then run this code: Message msg = new ADT_A01(); msg.initQuickstart("ADT","A01", "X"); // throws NumberFormatException -Mike |