Cut bread in to ¾ inch cubes and lay on a baking sheet and toast in the oven 10 minutes.
If adding bacon, spread out on a foil lined baking sheet and bake in the oven 20 minutes or until crisp. (Blot, then cut into small pieces)
In a large skillet, heat oil over medium high heat. Add thinly sliced onions. Saute, mixing often for 2-3 minutes, then turn heat down to medium low, continuing to cook until golden and tender, about 10 minutes. In another large skillet, heat butter over medium heat. Add sliced mushrooms and cook until tender, about 10 minutes. Add fresh thyme and a generous 3 finger pinch of salt and pepper, and cook off any liquid. Add the caramelized onions to the mushrooms and set aside.
In a medium bowl, whisk eggs, milk, sour cream, salt and pepper.
In a large bowl, add the toasted cubed bread. To this add the mushroom-onion-thyme mixture and bacon crumbles if using. Add the grated cheese and ⅔ of the crumbled goat cheese (saving the rest for the top) and gently mix.
Pour in the eggs and give a gentle stir. Let stand 5 minutes.
Stir again and pour into a well greased 4 quart baking dish. (At this point you could refrigerate overnight).
Cover with foil and place the 400 F oven and bake 35 minutes, Uncover, lower heat to 375 F and continue baking 20-30 more minutes until puffed and golden. During the last 10 minutes of baking, scatter the remaining goat cheese over the top and let it melt.
Garnish with a few thyme sprigs.
If refrigerating overnight, be sure to remove from fridge 40-60 mins before baking, so it comes to room temperature. Feel free to add spinach, arugula or other greens to the mushroom mixture for a boost in nutrients.