Microsoft Bond

From Wikitia
Jump to navigation Jump to search
Microsoft Bond
Developer(s)Microsoft
Initial releaseJanuary 2015; 7 years ago (2015-01)
RepositoryN/A
Operating systemWindows, macOS, Linux
PlatformCross-platform
Type
  • Serialization format and library
  • Interface description language compiler
LicenseMIT License

Microsoft Bond is an open-source cross-platform framework used for working with schematized data. It uses an interface description language to describe the structure of the data, which is used for generating code in a targeted programming language to parse or emit a stream of bytes representing this structured data. It is used broadly in Microsoft's cloud services.[1][2][3]

Overview

Microsoft announced and open sourced Bond in early 2015 under the MIT License.[4] It is used schema rules and a rich type system to serialize and deserialize data in a backwards and forwards compatible manner.

Bond currently supports C++, C#, Java and Pyton on Lunux, MacOS and Windows.[1]

Microsoft Bond is similar to the Apache Thrift (used by Facebook), Ion (created by Amazon), or Protocol Buffers (created by Google).[5][6]

Data structures are defined in a .bond file and compiled via gbc, the Bond compiler/codegen tool.[7]

Example

Bond schemas are defined in field names, along with integers that identify each field. The protocol itself only uses the integers, saving space for the field names during the transmission of the data. The names are only used in the generated code for readability.

namespace Examples

struct Record
{
    0: string Name;
    1: vector<double> Constants;
}

Language support

Bond currently supports:[8]

  • C++11)
  • C#
  • Java
  • Python

References

  1. 1.0 1.1 "A Thorough Guide to Bond for C#". microsoft.github.io. Retrieved 2020-09-18.
  2. "Azure Relay – cross-platform, open-protocol connections". azure.microsoft.com. Retrieved 2020-09-19.
  3. "The week in .NET - Bond - The Gallery". .NET Blog. 2016-10-18. Retrieved 2020-09-19.
  4. "Microsoft Open Sources Cross-platform Serialization Library – Bond". InfoQ. Retrieved 2020-09-15.
  5. "What are Protocol Buffers? Will they replace JSON?". Code Wall. 2019-10-16. Retrieved 2020-09-19.
  6. "Is JSON and XML your REST performance bottleneck?". TheServerSide.com. Retrieved 2020-09-19.
  7. https://microsoft.github.io/bond/manual/compiler.html
  8. microsoft/bond, Microsoft, 2020-09-16, retrieved 2020-09-18

External links

This article "Microsoft Bond" is from Wikipedia. The list of its authors can be seen in its historical. Articles taken from Draft Namespace on Wikipedia could be accessed on Wikipedia's Draft Namespace. [[Category:Cross-platform free software