where can I buy a new replacement barrel type lock? I have two devices that use this style of lock but when I bought the one it never locks. I can pull the key out and still rotate the little piece the holds it in place. My other lock works fine but I would like to have an extra in case it fails. Thank you.
Dhgate. Holy Trainer website. Probably also find on eBay or Amazon. Technically these were developed as furniture locks for old furniture that used skeleton keys.
here is a link to one i purchased from amazon https://www.amazon.com/gp/product/B01MEHVFJB/ref=oh_aui_search_asin_title?ie=UTF8&psc=1
Note that the one on the Amazon link provided by @NeedingToBeLocked is one of the better quality barrel locks - you can tell in the picture by the 3 circular pins holding the lock tumblers in. The cheaper style is just a piece of brass stamped onto the top; that brass piece often falls off. While you can get the decent ones on DHGate, you have to check the pictures carefully, and hope they don't run out. Also, buy a backup.
The HappyGo locks I purchased from Amazon were great, and worked smoothly. The ones I purchased more recently did not operate as smoothly - it could simply have been the cut of the key, but so far they've all held up well.