Is tokio codec Framed cancel safe?

Assuming you mean "the send method from SinkExt", yes. Similar to how all streams have a cancel-safe next method, all sinks have a cancel-safe send method. (with cancel safe having exactly the meaning that you mentioned here)

Other methods on SinkExt may or may not be cancel safe, but generally, they're cancel safe whenever they send at most a single message.

I'm a maintainer of Tokio and tokio-util.