I placed a mantis in my old tank's refugium and there was the clicking patterns and then the holes in the rock. I have witnessed the mantis (peacock mantis shrimp) lean back then smash his/her appendage into the rock. He/she was literally pounding out a cave to live in.
The clicking maybe a pistol shrimp but that pattern you indicate sounds like a mantis. Pistol shrimp tend to make a louder, cracking sound that sounds more like glass cracking than just the clicking. In any case, it is rare but possible for a mantis to stow onto live rock.
Assuming you have a mantis; try to isolate which rock or area of rock the sounds maybe be coming from, check for larger holes as well and carefully remove them to an appropriate container (
wear aquarium gloves). From there you can use a long thin piece of plastic to pierce the holes and dump the mantis out. Stowaways are usually very small and are more opportunistic than fierce hunters like the older, larger ones. Still, you are better off playing it safe and
wearing good gloves. A stow away would probably be more than satisfied eating what you provide rather than killing livestock but why take a chance. You could also try trapping but mantis shrimp tend to be notoriously difficult to trap.
Hope this helps
