Buy the oysters. When buying oysters, look for a tag with the harvest date and use them within a week of that date. Also, make sure the oysters are fresh and alive; the shells should be tightly closed or should close when tapped.
Chill and clean. Put the oysters in a colander of ice when you get home, then place the colander in a bowl and refrigerate. When you're ready to cook, scrub the oysters with a stiff brush under cold running water to remove any grit (a clean nail brush works well).
Shuck the oysters. Hold the oyster, curved-side down, in a towel on a cutting board. Insert an oyster knife between the shells at the narrow pointed end. (Use a real oyster knife-there is no substitute!) Press down firmly on the oyster to prevent slipping and twist the knife to pry the shells apart. Use the knife for leverage; do not use force. Cut the muscle that connects the oyster to the top shell with the knife, being careful not to pierce the meat. Remove the top shell. Slide your knife under the oyster to loosen it, keeping the meat and liquid in the shell. Use your knife to carefully scrape away any shards of shell.
Make the aioli. Blend the garlic, egg yolks, lemon juice and a pinch of salt in a food processor. Slowly drizzle in the olive oil with the motor running and process until thick. Use a rubber spatula to transfer the aioli to a bowl, then cover and refrigerate.
Prepare the ragout. Cook the bacon in a skillet over medium heat, stirring, until crisp. Add the shallots and mushrooms and cook 5 minutes, stirring. Add the garlic, cook 3 minutes, then add the butter and thyme. Season with salt and pepper.
Assemble the oysters. Preheat the broiler. Place the oysters, in their shells, in individual flameproof baking dishes or one large flameproof dish. (Put a crumpled sheet of foil underneath them to keep them steady, if necessary.) Top each with a spoonful of mushroom ragout.
Finish the dish. Top each oyster with a dollop of aeoli. Broil until the aeoli is golden, about 2 minutes, and serve immediately.