The Javadoc for PacketInterceptor indicate :
An exception can only be thrown when
processedis false which means that the read packet has not been processed yet or the packet was not sent yet. If the exception is thrown with a “read” packet then the sender of the packet will receive an answer with an error. But if the exception is thrown with a “sent” packet then nothing will happen.
To summarize the PacketInterceptor.interceptPacket is called 4 times :
incoming true + processed false = feedback
incoming true + processed true = no feedback
incoming false + processed false = no feeback
incoming false + processed true = no feedback
So, if the status incoming is false (the message is being sent) and the status processed is false, the message has not been processed.
In that particular case, shouldn’t the exception return an answer with an error to the sender as well?