We had a cake which was made for our school opening and we need to find something to spray on to preserve the cake? For the future. We called other cake shops but they didn't have anything we could how used.
The first thing would be making it as hollow as possible (probably eating the removed matter) ... the less massive it is, the easier it will be to treat.
Just spraying something on will not help unless the inside mass is either very dry (water activity) or sterile (won't be unless it was heated through to >120°C ... no it wasn't during baking!).
You would need to either replace ALL water in it with something else, or make sure ALL water is bound up or poisoned - all even harder to do without making it dangerous to a misguided person (children and animals! "Looks like food but is poison" is always an accident waiting to happen) mistaking it for an edible cake... it might be possible though, if you can get it down to a thin inner layer close to the icing - and manage not to damage the icing. A massive amount of salt would be the most obvious agent (and if someone eats it by accident, they will quickly realize they cant eat it) ... but would need to be sealed in too in order not to attract more moisture that will dissolve salt and icing.
Sealing the cake in and treating it with ionizing radiation to the point of sterilizing it would be rather impractical, heating it to the point would discolor, crack or melt it.
If you are lucky, the bare icing and decoration (if you can get it that hollow while preserving structural integrity long enough to backfill it with something inert) is dry enough/can be dried enough to be microbe and mold-proof, like lump sugar would be - even then, do not forget to deal with insects that would go for dry sugar.
Sealant? Maybe, just maybe, sodium silicate, since it has historically been used near food (egg preservation).
Depending on what you want to do with your cake in the end you could (or should not) use the following tricks:
I want to keep my cake and eat it! (afterwards):
- Put it in the fridge: it'll keep for another few days.
- Dump it in a sealed plastic bag in the freezer: it'll keep for another few months.
- Dump it in a glass jar full of 200°C (400°F) grape seed oil: it'll keep for another few years. (though it'll taste rather rich afterwards)
- Dump it in a glass jar full of 50 Volume% (100 proof) alcohol similar to a Rum Baba: it'll keep for another few decades. (though you might get jailed for DUI if you eat a piece of it and then drive)
I want to keep my cake:
- Leave it in a very clean oven (cleaned with soap, then vinegar then alcohol) to dry for one hour at 50°C (120°F) for every pound of cake and spray it with hair spray after it has cooled down: You'll end up with a nice glossy cake that'll still look good for another few months.
- Drop it in a glass jar filled with 250°C (500°F) mineral oil: it'll still look good for another few years.
- Drop it in an glass jar filled with formaldehyde: that's the stuff they use in museums to preserve fish in. Close the jar well and you'll enjoy it until the end of your life time!