Place racks in the upper and lower thirds of your oven and preheat oven to 400 degrees F. Line two large baking sheets with silicone baking mats or parchment paper. Set aside.
In a large skillet over medium low heat, heat 1 tablespoon olive oil and add the onions and salt. Sauté the onions until beginning to brown, then reduce heat to low and continue to cook, stirring occasionally, until deeply golden and caramelized, about 25 minutes. Remove the onions to a large bowl and set aside.
In the same skillet, heat the remaining tablespoon olive oil over medium low and sauté the mushrooms until tender, about 5 minutes. Add garlic, thyme, and black pepper and sauté 1 additional minute. Place in the bowl with the onions. Stir in the cheese
On a lightly floured work surface, roll out the puff pastry into an even 10.5-inch square. With a 2-inch round cookie cutter, cut the pastry into rounds (alternatively, you can slice the puff pastry into squares). You should have approximately 5 rows of 5 rounds (25 total rounds per sheet). Transfer the cut puff pastry to a prepared baking sheet, then brush lightly with the beaten egg. Prick each round with a fork to allow air to escape, then top each round with a scant 1/4 teaspoon of the whole grain mustard, then 1 tablespoon of the mushroom and onion filling. Repeat with the second pastry sheet.
Bake for 25 minutes, until the pastry is golden and crisp, rotating the pans 180 degrees and switching the positions of the baking sheets on the upper and lower racks halfway through. Let bites cool 5 minutes. Garnish with fresh parsley and serve warm or at room temperature.
To make this recipe ahead of time: Fully bake the recipe and place in an airtight container separating any layers with parchment or wax paper and freeze it (for up to two weeks). To serve, reheat directly from frozen in a 400 degree F oven for 5 minutes, or until hot. Alternatively, the mushroom onion topping can be prepped and refrigerated 2 days in advance. Top the cut puff pastry just before baking.
When cooking the samosas, start with the underside to seal the dough. For a lighter version, bake the samosas in an oven for 10 minutes at 180°C / Gas Mark 4.