locked
Serialization Options and Performance Testing tools/techniques for WinCE embedded software RRS feed

  • Question

  • Hi,

    In my WinCE embedded application we are saving the generated data in the xml file XMLSerializer. When XML file is more than 2MB size, it is taking lot of time to load the file (i.e both deserialization and populating grid in the UI) into a grid.

    Q1: Does anybody have come across problem like? If yes, which method/technique you used to solve the loading issues?

    Other serialization options I know are

    1. Binary Serialization

    2. JSON Serialization

    But not tried yet.

    Q2: Does anybody know how Binary and JSON serializations performance instead of XML serialization?

    Q3: Is there any better serialization methods?

    Q4: How to measure the performance of these methods on WinCE embedded device? i.e tools or techniques

    Thanks in advance,

    arkv999

    Tuesday, August 2, 2011 9:07 AM

Answers

  • A1: Sure. Solution is to use proper storage methods, store less data, etc.

    A2: Binary serialization has the best performance and smallest size. JSON is somewhat more compact than XML but closer to XML than to binary. It is noticeably faster than XML but not as fast as binary.

    A3: Generally yes but only XML serialization is supported on NETCF.

    A4:

    1. Start timer (e.g. use Stopwatch class).

    2. Do serialization.

    3. Stop timer.

    4. Compute time difference. That would indicate performance (smaller time is better).

    In any case it sounds like your application does not need serialization, it needs a database. Consider using SQL CE to store data.


    This posting is provided "AS IS" with no warranties, and confers no rights.
    • Proposed as answer by Jesse Jiang Thursday, August 4, 2011 6:22 AM
    • Marked as answer by Jesse Jiang Thursday, August 11, 2011 9:34 AM
    Tuesday, August 2, 2011 3:44 PM

All replies

  • A1: Sure. Solution is to use proper storage methods, store less data, etc.

    A2: Binary serialization has the best performance and smallest size. JSON is somewhat more compact than XML but closer to XML than to binary. It is noticeably faster than XML but not as fast as binary.

    A3: Generally yes but only XML serialization is supported on NETCF.

    A4:

    1. Start timer (e.g. use Stopwatch class).

    2. Do serialization.

    3. Stop timer.

    4. Compute time difference. That would indicate performance (smaller time is better).

    In any case it sounds like your application does not need serialization, it needs a database. Consider using SQL CE to store data.


    This posting is provided "AS IS" with no warranties, and confers no rights.
    • Proposed as answer by Jesse Jiang Thursday, August 4, 2011 6:22 AM
    • Marked as answer by Jesse Jiang Thursday, August 11, 2011 9:34 AM
    Tuesday, August 2, 2011 3:44 PM
  • Thank you.

    A3: Generally yes but only XML serialization is supported on NETCF.

    Can't I use Binary Serialization on NETCF?

    Wednesday, August 3, 2011 5:28 AM
  • You can, but you would need to write serializer yourself or find a 3rd party one.


    This posting is provided "AS IS" with no warranties, and confers no rights.
    Wednesday, August 3, 2011 6:21 AM