Uploaded image for project: 'QuickFIX/J'
  1. QuickFIX/J
  2. QFJ-786

First three fields getting truncated when converting from string to message using Message constructor

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 1.5.3
    • Fix Version/s: 1.6.0
    • Component/s: Engine
    • Labels:
      None
    • Environment:
      windows

      Description

      when using below code sinppet either first or second or third tag getting truncated.

      scenario 1:
      public class TestMessage {

      public static void main(String[] args) {
      String st = "35=D12=0.00000113=215=HKD21=222=538=300040=148=2318.HK54=255=2318.HK58=<AP9211WDAM><USU><CHK> namke59=060=20140507-11:10:02.000";

      quickfix.Message msg;
      try

      { msg = new Message(st,false); System.out.println("original message"+st); System.out.println("quickfixj message"+msg); }

      catch (InvalidMessage e)

      { // TODO Auto-generated catch block e.printStackTrace(); }



      }

      }
      Output =
      original message 35=D12=0.00000113=215=HKD21=222=538=300040=148=2318.HK54=255=2318.HK58=<AP9211WDAM><USU><CHK> namke59=060=20140507-11:10:02.000
      quickfixj message 9=13612=0.00000113=215=HKD21=222=538=300040=148=2318.HK54=255=2318.HK58=<AP9211WDAM><USU><CHK> namke59=060=20140507-11:10:02.00010=232
      First tag 35=D which was present in original string is missing after converting to message.

      Scenario 2:
      public class TestMessage {

      public static void main(String[] args) {
      String st = "8=FIX4.29=11012=0.00000113=215=HKD21=222=538=300040=148=2318.HK54=255=2318.HK58=<AP9211WDAM><USU><CHK> namke59=060=20140507-11:10:02.000";

      quickfix.Message msg;
      try { msg = new Message(st,false); System.out.println("original message "+st); System.out.println("quickfixj message "+msg); } catch (InvalidMessage e) { // TODO Auto-generated catch block e.printStackTrace(); }

      }

      }
      Output:
      original message 8=FIX4.29=11012=0.00000113=215=HKD21=222=538=300040=148=2318.HK54=255=2318.HK58=<AP9211WDAM><USU><CHK> namke59=060=20140507-11:10:02.000
      quickfixj message 8=FIX4.29=12413=215=HKD21=222=538=300040=148=2318.HK54=255=2318.HK58=<AP9211WDAM><USU><CHK> namke59=060=20140507-11:10:02.00010=182

      Now you can see third tag which is 12=0.000001 is truncated.

        Attachments

          Activity

            People

            • Assignee:
              chrjohn Christoph John
              Reporter:
              rpotluri raghuram potluri
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: