How to make sure that I do not break the glass bowl in a double boiler?
Thickness is not an indicator of heat-proof glass, just think about laboratory glassware, which is sometimes quite thin. It’s rather the other way round, thermal conductivity is low for glass which can increase inner tension when heated quickly. Thicker glass will be more robust against mechanical force, simply because it’s thicker.

If you want to be sure, get a bowl that is labeled as “heat-proof” or similar (terms may vary). It’s still a good idea to avoid sudden temperature swings, just to be sure although some manufacturers claim that their products can withstand temperature swings of 150K. It shouldn’t be an issue with melting chocolate, because you should place the bowl over (not “in” or “touching”) barely simmering water anyway and not have the water in the lower pot at a full rolling boil. There’s a good chance that even non-ovenproof bowls will stand up to this, but as you experienced, it can go wrong.

Another, often overlooked factor is the tension within the heated glass, especially if the temperature distribution is uneven (again: don’t boil the water at full speed). The glass will be more sensitive to shocks, so don’t bang the bowl with a metal spoon when stirring or getting leftovers off the spoon and don’t set it down hard on the table or counter.