PURDUE UNIVERSITY GRADUATE SCHOOL Thesis/Dissertation Acceptance
Total Page:16
File Type:pdf, Size:1020Kb
Graduate School Form 30 Updated 12/26/2015 PURDUE UNIVERSITY GRADUATE SCHOOL Thesis/Dissertation Acceptance This is to certify that the thesis/dissertation prepared By GEETHA R SATYANARAYANA Entitled A QUANTITATIVE COMPARISON & EVALUATION OF PROMINENT MARSHALLING/UN-MARSHALLING FORMATS IN DISTRIBUTED REAL-TIME & EMBEDDED SYSTEMS For the degree of Master of Science Is approved by the final examining committee: JAMES H HILL Chair RAJEEV RAJE MIHRAN TUCERYAN To the best of my knowledge and as understood by the student in the Thesis/Dissertation Agreement, Publication Delay, and Certification Disclaimer (Graduate School Form 32), this thesis/dissertation adheres to the provisions of Purdue University’s “Policy of Integrity in Research” and the use of copyright material. Approved by Major Professor(s): JAMES H HILL SHIAOFEN FANG 7/12/2016 Approved by: Head of the Departmental Graduate Program Date A QUANTITATIVE COMPARISON & EVALUATION OF PROMINENT MARSHALLING/UN-MARSHALLING FORMATS IN DISTRIBUTED REAL-TIME & EMBEDDED SYSTEMS A Thesis Submitted to the Faculty of Purdue University by Geetha R. Satyanarayana In Partial Fulfillment of the Requirements for the Degree of Master of Science August 2016 Purdue University Indianapolis, Indiana ii To Amma & Appa iii ACKNOWLEDGMENTS \All that I am, or hope to be, I owe it to my angel mother." I cannot begin to imagine how life would have been if it weren't for all the hardships my mother had to go through, and all the sacrifices she had to make as a single mother to bring my brother and me to where we are today. I cannot thank her enough for her love, her support, her belief in me and her constant motivation to give my best in everything I do. She has always been my biggest strength and inspiration, and will always be. I am very grateful for having such a wonderful mother and I truly owe everything I am to her. I am also eternally thankful to my late father, who has showered his blessings on me, at all times. I would like to thank my advisor, and Guru, Dr. James H. Hill for making me a part of his team, and teaching me good software design and principles. His ideas, support and motivation while doing my research project during the past two years has not only made me a better software engineer, but also a stronger person. I would like to thank Dr. Rajeev Raje, for being on my committee and also for teaching me the concepts of distributed systems, which interested me so much that I want to pursue it as a future career path. I also thank Dr. Mihran Tuceryan for willingly accepting to serve as my committee member. I would like to thank the Department of Computer Science, IUPUI, for funding the most part of my tuition expenses for my courses and research work at IUPUI, and also giving me the opportunity to be a teaching assistant for the last two semesters, which has been an invaluable experience. I would like to thank Nicole Wittlief for her support in all administrative matters. I would like to thank Meagan Senesac, my supervisor at the Office of Undergraduate Admissions, IUPUI, for giving me the opportunity to work for her, and her support to pursue my academics along with the part-time work. I would like to thank Manjula Peiris and Dennis Feiock, for assisting iv me whenever I had trouble moving forward with my project, and helping me achieve my research goals. I would like to thank the two men in my life, my brother Vaidyanathan, and my fianc´eHayawardh, for their belief in me, that I could achieve everything I want. I truly couldn't have achieved this without their love and support. I would also like to thank all my family, especially my uncle Mr. G Neelakantan and aunt Mrs. Chitra Neelakantan, for their love and moral support. I would like to thank all my friends for helping me during tough times, and being there for me when needed. Finally, I would like to thank the Almighty, for bringing all these wonderful people in my life, and also for giving me the strength to pursue all my personal and career goals. v TABLE OF CONTENTS Page LIST OF TABLES :::::::::::::::::::::::::::::::: vii LIST OF FIGURES ::::::::::::::::::::::::::::::: viii ABBREVIATIONS :::::::::::::::::::::::::::::::: ix ABSTRACT ::::::::::::::::::::::::::::::::::: x 1 INTRODUCTION :::::::::::::::::::::::::::::: 1 1.1 Thesis Organization ::::::::::::::::::::::::::: 3 2 RELATED WORKS ::::::::::::::::::::::::::::: 4 2.1 Native Data Representation :::::::::::::::::::::: 4 2.2 Lightweight Communication & Marshalling :::::::::::::: 5 2.3 Self adaptive data marshalling ::::::::::::::::::::: 6 3 BACKGROUND ::::::::::::::::::::::::::::::: 7 3.1 Open Source Architecture for Software Instrumentation of Systems 7 3.2 Binary JSON :::::::::::::::::::::::::::::: 9 3.3 Common Data Representation ::::::::::::::::::::: 10 3.4 Financial Information eXchange (FIX) Adapted for STreaming ::: 13 4 INTEGRATING VARIOUS DATA INTERCHANGE FORMATS INTO OA- SIS ::::::::::::::::::::::::::::::::::::::: 17 4.1 Challenges with the Existing Data Interchange Framework in OASIS 17 4.2 The New Data Interchange Framework in OASIS :::::::::: 20 4.3 Sending Data Encapsulations ::::::::::::::::::::: 25 4.4 Optimizing the Integration of QuickFAST for Better Performance : 26 5 EXPERIMENTATION, ANALYSIS & DISCUSSION ::::::::::: 30 5.1 Qualitative differences between CDR, BSON & FAST :::::::: 30 5.2 Experimental Setup ::::::::::::::::::::::::::: 31 5.3 Experiment 1: Size of packaged data ::::::::::::::::: 34 5.3.1 Setup & Results ::::::::::::::::::::::::: 34 5.3.2 Analysis ::::::::::::::::::::::::::::: 35 5.4 Experiment 2: Throughput & Latency :::::::::::::::: 36 5.4.1 Setup & Results ::::::::::::::::::::::::: 36 5.4.2 Analysis ::::::::::::::::::::::::::::: 38 5.5 Experiment 3: Processing times :::::::::::::::::::: 39 vi Page 5.5.1 Setup & Results ::::::::::::::::::::::::: 39 5.5.2 Analysis ::::::::::::::::::::::::::::: 41 5.6 Discussion 1: Packaging Time Vs. Throughput :::::::::::: 42 5.7 Discussion 2: Packaging Time Vs. Latency :::::::::::::: 44 5.8 Discussion 3: Extrapolation of Results :::::::::::::::: 45 5.9 Summary of Experimental Results ::::::::::::::::::: 46 6 CONCLUSION & FUTURE WORKS :::::::::::::::::::: 47 6.1 Future Works :::::::::::::::::::::::::::::: 48 6.1.1 Algorithm to choose from different formats based on the data 48 6.1.2 Comparison of different binary compression formats ::::: 48 REFERENCES :::::::::::::::::::::::::::::::::: 50 vii LIST OF TABLES Table Page 3.1 Element types in BSON for standard data types ::::::::::::: 9 3.2 Octet Alignment requirements of primitive data types in CDR. ::::: 12 viii LIST OF FIGURES Figure Page 3.1 High level overview of OASIS. ::::::::::::::::::::::: 7 4.1 Existing packaging framework in OASIS ::::::::::::::::: 17 4.2 Existing un-packaging framework in OASIS ::::::::::::::: 19 4.3 New packaging/un-packaging framework in OASIS :::::::::::: 21 4.4 Using the new packaging/un-packaging framework :::::::::::: 24 4.5 Data Packet Channel & Node Packet Channel :::::::::::::: 26 4.6 Framework Changes to improve performance of FAST :::::::::: 28 5.1 Packaged data size (in bytes) for each of the data interchange for varying number of probe elements. ::::::::::::::::::::::::: 34 5.2 Average Throughput for each of the data interchange for varying number of probe elements. ::::::::::::::::::::::::::::: 37 5.3 Average Latency (in microseconds) for each of the data interchange for varying number of probe elements. :::::::::::::::::::: 38 5.4 Average Packaging time (in nanoseconds) for each of the data interchange formats for varying number of probe elements. :::::::::::::: 40 5.5 Average Un-Packaging time (in nanoseconds) for each of the data inter- change formats for varying number of probe elements. :::::::::: 41 5.6 Average Packaging time (in nanoseconds) Vs. Throughput for each of the data interchange formats :::::::::::::::::::::::::: 43 5.7 Average Packaging time (in nanoseconds) Vs. Latency (in microseconds) for each of the data interchange formats ::::::::::::::::: 44 ix ABBREVIATIONS ACE Adaptive Communication Environment BSON Binary JSON CDR Common Data Representation CORBA Common Object Request Broker Architecture DAC Data and Acquisition Controller DDS Data Distribution Services DRE Distributed Real-time and Embedded EINode Embedded Instrumentation Node FAST FIX Adapted for STreaming FIX Financial Information eXchange Gbps Gigabits per second GIOP General Inter-ORB Protocol IDL Interface Definition Language JSON JavaScript Object Notation OASIS Open Source Architecture for Software Instrumentation of Sys- tems OMG Object Management Group ORB Object Request Broker PDL Probe Definition Language UBJSON Universal Binary JSON UUID Universally Unique Identifier x ABSTRACT Satyanarayana, Geetha R. MS, Purdue University, August 2016. A Quantitative Comparison & Evaluation of Prominent Marshalling/Un-Marshalling Formats in Dis- tributed Real-time & Embedded Systems. Major Professor: James H. Hill. This thesis demonstrates a novel idea on how components in a distributed real-time & embedded (DRE) system can choose from different data interchange formats at run- time. It also quantitatively evaluates three binary data interchange protocols used in distributed real-time & embedded (DRE) systems: the Common Data Representation (CDR), which collects data \as-is" into a buffer; Binary JSON (BSON), which enables \on the fly" discovery of elements in a message; and FIX Adapted for Streaming (FAST), which is a binary compression algorithm popularly used for data exchange in financial stock market domain. We compare these three data exchange formats