I have used ultrasonic cleaners for many years, but not for cleaning guns.
What I would do - would be to put water in the ultrasonic tank, and then put the cleaning solution in a smaller container that would hold the part to be cleaned. I actually used a glass beaker, but anything that will transfer the ultrasonic energy will work - you can see the bubbles in the inner container. This is beneficial for 2 reasons, one it is easy to dump the cleaning liquid, and secondly the dirty cleaning solution is not in the ultrasonic tank.
Keep in mind that extended ultrasonics can cause premature failure of materials, due to the propagation of stress cracks.