Concise Binary Object Representation (CBOR, RFC7049)

Edit Package perl-CBOR-XS

This module converts Perl data structures to the Concise Binary Object Representation (CBOR) and vice versa. CBOR is a fast binary serialisation format that aims to use an (almost) superset of the JSON data model, i.e. when you can represent something useful in JSON, you should be able to represent it in CBOR.

In short, CBOR is a faster and quite compact binary alternative to JSON, with the added ability of supporting serialisation of Perl objects. (JSON often compresses better than CBOR though, so if you plan to compress the data later and speed is less important you might want to compare both formats first).

To give you a general idea about speed, with texts in the megabyte range, 'CBOR::XS' usually encodes roughly twice as fast as Storable or JSON::XS and decodes about 15%-30% faster than those. The shorter the data, the worse Storable performs in comparison.

Regarding compactness, 'CBOR::XS'-encoded data structures are usually about 20% smaller than the same data encoded as (compact) JSON or Storable.

In addition to the core CBOR data format, this module implements a number of extensions, to support cyclic and shared data structures (see 'allow_sharing' and 'allow_cycles'), string deduplication (see 'pack_strings') and scalar references (always enabled).

The primary goal of this module is to be _correct_ and the secondary goal is to be _fast_. To reach the latter goal it was written in C.

Refresh
Refresh
Source Files
Filename Size Changed
CBOR-XS-1.87.tar.gz 0000080713 78.8 KB
cpanspec.yml 0000000663 663 Bytes
perl-CBOR-XS.changes 0000003962 3.87 KB
perl-CBOR-XS.spec 0000003401 3.32 KB
Latest Revision
Tina Müller's avatar Tina Müller (tinita) committed (revision 13)
Fix disabling of __perllib_provides
Comments 0
openSUSE Build Service is sponsored by