Drain and rinse jackfruit. Heat olive oil in large pan on medium heat and add jackfruit and onions. Sauté 3-4 minutes, or until the onions become slightly translucent.
Add garlic, bay leaves, rosemary and 2 cups milk. Turn heat down to low, cover. Simmer 25 minutes until jackfruit has softened. Using two forks, shred jackfruit. Add remaining ½ cup milk.
Add carrots, potatoes and peas. Turn heat up to medium and simmer for 15 minutes or until vegetables have softened. Discard bay leaves and rosemary. Taste, add salt and pepper as desired.
Remove pan from heat and drain mixture in colander over bowl, reserving infused milk. If reserved milk doesn’t equal 1 cup of liquid, add extra milk.
Preheat the oven to 375° F.
Wipe the pan clean and heat butter over low heat. Once melted, whisk in flour until it forms a paste that moves away from sides of pan. Cook another 1-2 minutes.
Pour in half of reserved infused milk and allow mixture to boil. Boil 2 minutes, reduce heat to low and whisk thoroughly until roux starts to thicken. Once all lumps are gone add the other half of the milk. Whisk again thoroughly until smooth. Remove from heat and stir in vegetables.
Pour mixture into small stoneware casserole dish (approximately 1 quart).
Unfold thawed puff pastry sheet. Lay over the dish, cut excess and crimp sides with fork. Brush the top of the pastry with melted butter. Cut 4 small slits in pastry. Sprinkle top with sea salt, if desired.
Bake in oven 20-25 minutes, or until top is golden brown.