Azure / go-amqp

AMQP 1.0 client library for Go.
https://github.com/Azure/go-amqp
MIT License
104 stars 56 forks source link

Audit all composite types to ensure they properly implement non-mandatory fields #107

Open jhendrixMSFT opened 2 years ago

jhendrixMSFT commented 2 years ago

Per http://docs.oasis-open.org/amqp/core/v1.0/os/amqp-core-types-v1.0-os.html#doc-idp115568

mandatory: "true" iff a non null value for the field is always encoded.

What this means is that for all non-mandatory fields in a composite type, they must be pointer-to-type. That said, we should be smart in how we fix things up. E.g. the description field in the error type isn't mandatory, however making it be *string doesn't really add any value.

richardpark-msft commented 2 years ago

(related: https://github.com/Azure/go-amqp/pull/93)