Over time, you are correct. However, it wouldn’t do it instantly (on a fresh barrel). I understand how a watercooled barrel like the Maxim works, but obviously I’m not referring to that. Again, I bring up the stories my Great-uncle would tell. He was there. In the heat of a battle, it was an option that they used from time to time. Yes it ruined the barrel afterwards, but at that moment it wasn’t their concern. Considering its only up for a very short time, it would’t be an issue.
If needed, they could put a cap on how many times it could be done.
Yes it would actually. Warping would occure instantly since you can’t cool it uniformly. If you use water you would pour it from above, meaning that the top side of the barrel would shrink while the bottom wouldn’t, causing the barrel to warp upwards. Heat treatment would be lost instantly and the chances of cracks are high.
Would it cause the barrel to fail instantly? not sure, depends on the barrel
Would it ruin the barrel instantly making it prone to failures? YES
Did some soldiers do it? Most likely
Is it something you would want to do to a barrel? Most certainly not, the risk of a barrel blowing on you is too high.
Physics are physics, they happen if we like it or not.