msgpack
msgpack copied to clipboard
The spec does not strictly define precedence within the output formats
According to this point: https://github.com/msgpack/msgpack/blob/master/spec.md#serialization
If an object can be represented in multiple possible output formats, serializers SHOULD use the format which represents the data in the smallest number of bytes.
The spec does not define precedence within the output formats. Because of that, it's up to the different implementations to decide either to favor extended types which override default ones or not to permit this approach. In most cases clients could highly compress some types (like strings) exploiting application-dependent patterns or something else by providing extensions. Despite of the advantages that this choice could lead to, some implementations do not test each format (that means mainly the extensions, even though they are for internally treated types like strings) and do not "use the format which represents the data in the smallest number of bytes".
I suspect that the problem is due to a misunderstanding of the spec itself and kindly suggest to define a behavior all the implementations have to adhere to.