Multiple servlets and routing in Vaadin 23

I have recently migrated an application from Vaadin 14 to Vaadin 23 with minimal issues. The Vaadin documentation has been excellent, and I have found the Vaadin Discord search to be a useful resource. While I have not encountered many issues with the Vaadin framework itself, some behaviors in the framework have changed, requiring some odd changes.
I would like to take a moment to congratulate the Vaadin team on their excellent engineering efforts.

One issue I am having with upgraded vaadin framework is around multiple servelets and navigation.

In the Vaadin 14 application, there are multiple servlets, one of which allows the user to download files/content by pressing a Vaadin button. The Vaadin servlet listens for all routes under /*, but there is another servlet located under /media/download. This setup worked without issues in Vaadin 14, but in Vaadin 23, it leads to “no routes found” errors.

I suspect this is because the Vaadin servlet cannot find any routes with the /media/download path and does not allow other servlets to respond to requests.

Would using a router-link with an option to skip routing be a good solution?

What would the recommended practice to resolve this problem?
thanks

How are you starting the download with the button?
If the button is not mandatory, you can perhaps use an Anchor element and set the router-ignore attribute

anchor = new Anchor("/media/download", "Download");
anchor.getElement().setAttribute("router-ignore", true);

Thanks @versatile-zorse , it worked.

If I understand correctly, using a router link with this attribute would tell the Vaadin router to ignore routing for that link. This, in turn, would allow other servlets to serve the request, which appears to be a behavior change between Vaadin 14 and Vaadin 23.

Exactly. It is documented in the migration guide
https://vaadin.com/docs/latest/upgrading/essential-steps/#miscellaneous-changes

thanks @versatile-zorse i did read that earlier but I may have not have remembered it. Amazing work!