nats icon indicating copy to clipboard operation
nats copied to clipboard

Deprecate and remove `NATS::Message#body`

Open jgaskins opened this issue 4 months ago • 0 comments

This will need to be a process rather than a one-and-done task. The body method is used everywhere and we should assume that users are also using it. So the body method should be deprecated until 2.0.

I added https://github.com/jgaskins/nats/commit/9517187a80c3da5e7e52965e9e6e3a02349daa52, which is the first step, but there are several more:

  • [ ] Add NATS::JetStream::Message#data
  • [ ] Update all internal code to use the data methods
  • [ ] Deprecate body from both NATS::Message and NATS::JetStream::Message
  • [ ] Remove body (and body_io) right before releasing 2.0

jgaskins avatar Jul 16 '25 20:07 jgaskins