What causes the chemical taste in commercial bakery products?
This could be a number of factors.


Parchment sheets are ubiquitous in professional, non-commerical bakeries. As the sheets are treated to impart some nonstick properties, you may be tasting some residue from that paper, especially if the bakery is using bleached sheets. You can easily test this by baking something at home on parchment and seeing if it has that same flavor. This is unlikely but hey, worth a shot. 
Commercial pan release sprays will sometimes contain suspended flour, anticaking agents (silicon dioxide for example,) and certain anti-foaming agents. When I worked in a bakery we would occasionally use a commercial spray like that when making items that were prone to sticking even on parchment, or when baking things that would be in direct contact with our metal baking pans (brownies, muffins, etc.) Most of the time we opted for a spray that was mainly canola oil and propellant, but occasionally we would use other sprays with additional ingredients.
Eggwash (or commercial substitute) is a potential culprit, especially as you mentioned croissants and danishes. We used a mix of egg and water sprayed on to certain items (mainly with puff pastry) before baking, but larger bakeries may use a product like Bake-Sheen sprayed before or after baking for the same effect. Those sprays contain several chemicals and would definitely impart a certain flavor to the items. Moreover, there is a possibility it could drip down and pool around the bottom of the item, creating that  
In terms of glazes, those would likely depend on what is being used by the bakery in question, and they won't always be similar. If you're experiencing this regularly from one place or another, it might help to ask what they glaze their danish or other items with. We used an apricot glaze product to give our sweet puff pastry items a shine and added sweetness. These commercial glazes likely have artificial or chemical flavoring agents in them, which may impart an off flavor.