I'm having trouble using Spring Mobile 1.1.2 and Spring MVC. The problem I'm having is, that in the application I have all views for desktop and for some desktop, I have mobile alternative.
I use LiteDeviceDelegatingViewResolver, which delegates to InternalResourceViewResolver. If both desktop and mobile views are present, everything works fine. On desktop I see desktop version, on mobile I see mobile version. The problem is when the mobile view is not present.
I know, that fallback resolution will only work when delegating to a view resolver which returns null from resolveViewName(String, Locale) if it cannot resolve a view. For example, InternalResourceViewResolver never returns null, so fallback resolution will not be available. So I didn't hope that will work.
But I tried to chain resolvers, with order 1 LiteDeviceDelegatingViewResolver(delegates to InternalResourceViewResolver) and with order 2 InternalResourceViewResolver (which point to desktop views all the time regardless on the device). My problem is, that it never gets to resolver number 2. Where is the problem?
Thanks
According to Spring doc you just need to enable fullback resolution.
hope it helps you !