preheat the oven to 400°F, or 200°C. Line a baking sheet with parchment paper.
Unfold the thawed puff pastry on a lightly floured work surface. Gently roll it into an even rectangle if needed.
Spread a thin layer of Dijon mustard or cream cheese over the pastry, leaving a small border around the edges.
Arrange the ham slices evenly over the pastry.
Add the cheese slices or sprinkle the shredded cheese evenly over the ham.
Starting with one of the long sides, carefully roll the pastry into a tight log. Avoid pressing too firmly, as this can push the filling out.
Wrap the pastry log in parchment paper or plastic wrap and chill it for about 15 minutes. Chilling makes the log easier to slice.
In a small bowl, whisk together the egg and milk or water to make the egg wash.
Use a sharp knife to slice the chilled log into approximately 12 rounds, each about ½ inch thick.
Place the pinwheels cut-side up on the prepared baking sheet, leaving space between each piece.
Brush the tops lightly with the egg wash.
Bake for 15–20 minutes, or until the pastry is puffed, golden brown, and crisp and the cheese has melted.
Remove the pinwheels from the oven and allow them to cool for 5 minutes before serving.