HTTP Status 404

Hi, I’m new un Vaadin. I have a silly error when I compile my Project:

When I want to se the web application always appear the same error:

HTTP Status 404 - /Example/WEB-INF/classes/com/example/example/ExampleApplication.java

--------------------------------------------------------------------------------

type Status report

message /Example/WEB-INF/classes/com/example/example/ExampleApplication.java

description The requested resource (/Example/WEB-INF/classes/com/example/example/ExampleApplication.java) is not available.

I don’t know why. It even occurs when I don’t modify a single line from the “Hello World” example.

I’m using JBoss Server v4.2 and the web.xml file is

<?xml version="1.0" encoding="UTF-8"?>
<web-app id="WebApp_ID" version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
	<display-name>Example</display-name>
	<context-param>
		<description>
		Vaadin production mode</description>
		<param-name>productionMode</param-name>
		<param-value>false</param-value>
	</context-param>
	<servlet>
		<servlet-name>Example Application</servlet-name>
		<servlet-class>com.vaadin.terminal.gwt.server.ApplicationServlet</servlet-class>
		<init-param>
			<description>
			Vaadin application class to start</description>
			<param-name>application</param-name>
			<param-value>com.example.example.ExampleApplication</param-value>
		</init-param>
	</servlet>
	<servlet-mapping>
		<servlet-name>Example Application</servlet-name>
		<url-pattern>/*</url-pattern>
	</servlet-mapping>
	<welcome-file-list>
		<welcome-file>index.html</welcome-file>
		<welcome-file>index.htm</welcome-file>
		<welcome-file>index.jsp</welcome-file>
		<welcome-file>default.html</welcome-file>
		<welcome-file>default.htm</welcome-file>
		<welcome-file>default.jsp</welcome-file>
	</welcome-file-list>
</web-app>

It could be the Server I have chose? If I change the direction of the browser that innitialy appears

http://localhost:8080/Example/WEB-INF/classes/com/example/example/ExampleApplication.java 

for this one (the same direction without /WEB-INF/)

http://localhost:8080/Example/classes/com/example/example/ExampleApplication.java

I can see properly the page

Thank you all for any suggestion

Simply use “http://localhost:8080/Example/” to open the application in the web browser.

Thank you for yor reply, Marko.

I was talking about the web browser of Eclipse, not Firefox or Chrome.

Any idea of what could be?

It doesn’t matter what web browser you use.

You don’t run Vaadin applications by giving a Java source file name, but the application name (context root to be exact - it’s defined in the project settings). In your case, it’s apparently “Example”.

The WEB-INF is a special directory that can not browsed - it is protected.

The URL without the WEB-INF path works just because everything after the “/Example/” is ignored.

Thank you a lot, Marko

as you can see, I’m very new in this stuff

Thank you again!!!

you can clean the project .