Since I started training hard, specially when training freestyle, my calluses ripped off, even bleeding and making training impossible for a couple days. I researched about this and doing my own experiments and created a "method" that I have been using for some time, with the result of only having problems with my calluses once in more than a year, muche better than before, that I had to stop training every now and then.
The method has 3 steps:
The calluses shown are the ones that you should trim to make them flat.
And that is it, with this method you will avoid calluses ripping off, because when that happens is, speaking simply, when they are like a little ball in your hand, that gets trapped in the bar as you rub against it, they get kind of caught in the middle and break.
Also if you don't have any calluses, because lack of training, your skin will be bland and soft, so little fold will form when you rub against the bar and those can also break. Thats why the ideal is to have calluses, but have them well flat and smooth.
In case that you are trying new tricks, specially the ones where you do big spins on the bar, it is possible that those put pressure on the center of your hand, where you probably don't have any calluses. To avoid ripping off the skin in that zone, practise those tricks 2 or 3 times at max in a day, so the calluses form and you treat them with the method explained.
I want to warn you that even if your calluses don't rip off and you have them perfectly treated, if you train a lot you can get them irritated and hurting. On that point you should stop training and rest your bar training for a day (perfect for floor or parallel bar training, or leg day).
About the use of gloves or gymnastic grips, I think they can be great for training your routines and basic exercises. Some people use them for freestyle and feel comfortable with that, but lots of people can't use them because they feel strange, slip, etc. so it is a case of personal preference. In my experience I sometimes use gymnastic grips to do routines and protect my hands, but for freestyle I don't use them. And even if you always use gloves or grips, you should keep treating your calluses.
Finally if they have already ripped off, what you need to do is to clean the wound and use a regeneration cream so it heals faster. The cream I use is called Blastoestimulin but if you ask in your pharmacy you will find one that works.
When the wound is healed you should cut the extra skin keep using the method explained above.