1) Bring a large pan of water to the boil, add salt and cook the pasta to just shy of al dente. Meanwhile, preheat the oven to 200C/Gas 6.
2) Chop the pancetta into 1/2cm cubes. Heat the olive oil in a large frying pan or skillet over a medium to medium-high heat. Add the pancetta and cook for 2 to 3 minutes.
3) Add the celery, carrot, onions, garlic, rosemary, thyme and bay leaf, and season with salt and pepper. Saute the vegetables until tender, 6 to 7 minutes.
4) Add the beans and heat them through. Stir in 125ml wine, simmer 30 seconds more and then turn off the heat. Remove the bay leaf.
5) While the vegetables cook, melt the butter in a small saucepan over a medium heat. Whisk in the flour and cook 1 minute, then whisk in the milk. Season the sauce with salt, pepper and nutmeg and reduce for 4 to 5 minutes. Stir in half the grated cheese, turn off the heat and adjust the seasoning to taste.
6) Drain the pasta and return it to the pan. Toss the pasta with the white bean topping and sauce, stirring to coat it fully. Transfer everything to a casserole dish, top with the remaining cheese and place in the oven to brown for 5 minutes.