Beet, mushroom and potato casserole

2 tbsp oil
1 medium onion, chopped
3 tbsp flour
1 1/4 cups vegetable stock
1 1/2 pounds cooked beets, peeled and chopped
5 tbsp light cream
2 tbsp creamed horseradish
1 tsp hot mustard
1 tbsp wine vinegar
1 tsp caraway seeds
2 tbsp butter
1 shallot, chopped
8 ounces mushrooms, trimmed and sliced
3 tbsp chopped fresh parsley

For the potato border:
2 pounds potatoes, peeled
2/3 cup milk
1 tbsp chopped fresh dill
salt and freshly ground black pepper

Preheat the oven to 375°F. Lightly oil a 9-inch round baking dish. Heat the oil in a large saucepan, add the onion and cook until soft, without coloring. Stir in the flour, remove from the heat and gradually add the stock, stirring until well blended.  Return to the heat, stir and simmer to thicken, and then add the beets, cream, creamed horseradish, mustard, vinegar and caraway seeds. To make the potato border, bring the potatoes to a boil in salted water and cook for 20 minutes. Drain well and mash with the milk. Add the dill, if using, and season with salt and pepper. Spoon the potatoes into the prepared dish and make a well in the center. Spoon the beet mixture into the well and set aside. Melt the butter in a large nonstick frying pan and cook the shallot until soft, without browning. Add the mushrooms and cook over moderate heat until their juices begin to run. Increase the heat and boil off the moisture. When quite dry, season with salt and pepper and stir in most of the chopped parsley. Spread the mushrooms over the beet mixture, cover and bake for about 30 minutes. Serve at once, garnished with the reserved parsley. If you are planning ahead, this entire dish can be made in advance and heated when needed. Allow 50 minutes baking time from room temperature. Serves 4-6