Preheat oven to 400°.
To prepare the fennel slice off the stalks and fronds (the green tops), slice off the root end, slice the bulb into halves and cut out the core from each half. Then slice the halves into thin slices.
Cut the onion into halves and then into thin slices.
Heat 2 tablespoons vegetable oil or butter in a large pot or saucepan over medium-high heat. Add fennel and onion, season with salt and pepper, and cook, stirring occasionally, until vegetables are soft and translucent, about 8 - 10 minutes, reducing heat if it starts to brown.
Add garlic and cook, stirring constantly until fragrant, about 30 seconds.
Add flour and stir to combine. Add milk or half and half, stir, and cook until thickened.
Add beans and adjust seasonings. Remove from heat.
Transfer the mix to a large casserole dish.
In a small bowl combine breadcrumbs and olive oil, use your fingers to mix the oil into the breadcrumbs. Add parmesan cheese, combine, and top the veggie mix with the topping.
Bake until golden brown on top and bubbling around the edges, about 20 - 30 minutes.