Wildfly 8.2 + Apache - Failed to load the bootstrap javascript: ./VAADIN/va


Failed to load the bootstrap javascript: ./VAADIN/vaadinBootstrap.js?v=7.5.3

Most annoying error ever. Have tried running multiple different applications and read through tons of forums posts and have tried everything. Even tried on Debian and CentOS servers. Same error no matter what. I never receive the issue on my instance of Wildfly 8.2 on my local machine. On the Debian instance I am using ProxyPass and ProxyPassReverse to allow access to the application.

I even set the same things up for Failed to load the bootstrap javascript: /VaadinTest/VAADIN/vaadinBootstrap.js

Anyone have any extra advice? I am really open to anything at this point. Thanks!

Class from basic maven archetype application. Application name is VaadinTest.

@Theme("mytheme")
@Widgetset("com.MyAppWidgetset")
public class MyUI extends UI {

    @Override
    protected void init(VaadinRequest vaadinRequest) {
        final VerticalLayout layout = new VerticalLayout();
        layout.setMargin(true);
        setContent(layout);

        Button button = new Button("Click Me");
        button.addClickListener(new Button.ClickListener() {
            @Override
            public void buttonClick(ClickEvent event) {
                layout.addComponent(new Label("Thank you for clicking"));
            }
        });
        layout.addComponent(button);

    }

    @WebServlet(value = {"/*", "/VaadinTest/*", "/VAADIN/*"}, asyncSupported = true)
    @VaadinServletConfiguration(productionMode = false, ui = MyUI.class)
    public static class MyUIServlet extends VaadinServlet {
        
    }
}

How is your proxy set up? Does your app URL end in a slash (/)? Check the inspector in the browser what URL it tries to load the javascript from. Is it correct? What is the response? Can you access the correct URL from the server? If so, why does the proxy request the wrong URL?

Thanks got part of it working on the Debian server. I needed to change:

ProxyPass /AppName
to
ProxyPass /AppName/

Sometimes when I refresh the page it just shows the default Vaadin loading icon and just hangs. A 2nd refresh will load the page.

On the CentOS server I will still randomly get the original error, or the can’t load the widget nocache.js error:
Failed to load the widgetset: ./VAADIN/widgetsets/com.vaadin.DefaultWidgetSet/com.vaadin.DefaultWidgetSet.nocache.js?1441653423942
or sometimes the webpage will refresh to a screen that shows the default html page with the number 0 at the top. (see attached file)

On the CentOS server the application sometimes actually runs just fine, but then once you click a button it breaks again with anyone of the above errors at random.

21141.rtf (2.29 KB)

On both servers the application will make a POST request based upon a user interact. (scroll in the grid, button click, text entry etc…) and then the blue loading line will slowly go across the top and then stop and flash right towards the top left hand side of the screen. After that everything crashes. This happens on both Debian and CentOS.