It can be quite a tricky balancing act. You'll get an idea of how to assess the variables involved as time goes by.
For me, I'd probably be looking at it like this:
1. I've bolused for the main meal, hope I've got that right but after an hour or so for the main meal and I'm approaching the dessert, the insulin will not be too far away from peak action, so I'll likely be getting a few clues at to whether I got the bolus call right, or was too low or high (pretty easy to do this with cgm, less so with strips).
2. If it seems I got it right, then it's extra carbs, so needs extra insulin, but remember that the first bolus you took will still be working for about five hours in total, so if you take another one, you've got two shots working in you at the same time with different peaking times. That can sometimes be unpredictable. It's called insulin stacking. There's nothing wrong with it but just be aware that the last two hours of the first shot can sometimes produce quite a drop on its own and if that combines with peak action of the second shot, you're heading South. So, if I'm insulin stacking, it's not uncommon for me to say, ok, would normally do x for this dessert but will shave y off it because I know I've already got the last bolus in me, peaking.
3. If it turns out I over-bolused for the main meal, and I'm dropping more than I'd like (again, easy enough to see with cgm), then a bit of cake is just the thing, might still need a bolus but seriously raked back.
4. There's cake, and then there's cake. I've never really had a sweet tooth, so not having a dessert course isn't an issue for me, but eclairs and profiteroles are basically mostly air and are relatively low carb, so a modest squirt will take care of them without having to think about stacking too much.
5. Avoid all of the above and have the cheeseboard instead!
Carveries and buffets can seem like a nightmare to begin with, but you'll get the hang of it. Best of luck!