<div dir="ltr">I noticed that a Channel.basicPublish to a non-existent exchange does not result in an exception being thrown. It&#39;s not clear from the docs whether this is expected or not, but I assumed an exception would be thrown here since attempting to get/consume from a non-existent queue results in an exception be thrown with a similar shutdown reason (404). The channel is shutdown, but since the Channel&#39;s shutdown listener might not be called immediately my client might not realize that the Channel has been closed and could attempt another publish which results in the Connection being shutdown as well.<div>
<div><br></div><div>Should Channel.basicPublish throw when the exchange doesn&#39;t exist? If not, what&#39;s the recommended way to determine if a basicPublish resulted in the Channel being closed (since Channel.isOpen is not recommended for production use) ?</div>
<div><br></div><div>Thanks,</div><div>Jonathan</div></div></div>