thrift_serialize

command
v1.27.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 21, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

A small cli utility meant to convert json to zipkin thrift binary format, and vice versa.

To convert from json to thrift, the json is unmarshalled, converted to zipkincore.Span structures, and marshalled into thrift binary protocol. The json must be in an array format (even if it only has one object), because the tool automatically tries to unmarshal the json into an array of structs.

To convert from thrift to json, the opposite process must happen. The thrift binary data must be read into an array of zipkin span structures, and those spans must be marshalled into json.

Usage:

./thrift_serialize -input <input-file> -output <output-file> -deserialize<true|false>

If `deserialize` is set to true (false by default), the tool will interpret the input file as thrift, and write it as json to the output file. Otherwise, the input file will be interpreted as json, and the output will be encoded as thrift.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL