Once the database is set up, you are ready to compile the project and deploy the resulting WAR archive to GlassFish 7. GlassFish must be running before deployment, and the MySQL service must be reachable onDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/LuisAMoralesA/tallerIngles-UAEMEcatepec/llms.txt
Use this file to discover all available pages before exploring further.
localhost:3306.
Compilar el proyecto
Ejecutar el empaquetado Maven
Clean any previous build output and produce the WAR file:Maven compiles all Java sources targeting Java 11, bundles the runtime dependencies (MySQL Connector/J, JasperReports, Apache POI, etc.), and writes the archive to:
Desplegar el WAR
Choose one of the two deployment methods below.Opción A: autodeploy
Copy the WAR directly into GlassFish’sautodeploy directory. GlassFish monitors this folder and deploys any new or updated archive automatically within a few seconds:
tallerDeInglesUAEM.war_deployed) in the same directory once deployment completes successfully, or tallerDeInglesUAEM.war_deployFailed if an error occurred.
Opción B: consola de administración
- Open the GlassFish Administration Console in your browser:
http://localhost:4848 - In the left panel, navigate to Applications.
- Click Deploy.
- Under Location, select Packaged File to Be Uploaded to the Server and choose
target/tallerDeInglesUAEM.war. - Leave the context root as
/tallerDeInglesUAEMand click OK.
Verificar el despliegue
The application is deployed under the context root/tallerDeInglesUAEM, which matches the Constantes.DOMINIO constant defined in controller/Constantes.java. Use the URLs below to confirm the application is running correctly after deployment.
| Portal | URL |
|---|---|
| Página principal | http://localhost:8080/tallerDeInglesUAEM/ |
| Login administrador | http://localhost:8080/tallerDeInglesUAEM/view/login/loginAdministrador.jsp |
| Login profesor | http://localhost:8080/tallerDeInglesUAEM/view/login/loginProfesor.jsp |
| Login alumno | http://localhost:8080/tallerDeInglesUAEM/view/login/loginAlumno.jsp |
Configuración del contexto
The context root/tallerDeInglesUAEM is derived from the <finalName> declared in pom.xml:
pom.xml
.war extension) as the context root when no explicit <context-root> is set in the deployment descriptor. The src/main/webapp/WEB-INF/glassfish-web.xml file configures the class loader and JSP behaviour but does not override the context root:
glassfish-web.xml
<class-loader delegate="true"/> directive tells GlassFish to use the parent class loader first, which is the correct behaviour for a Jakarta EE application that relies on APIs provided by the server.
Throughout the application, all internal URLs are built by prepending the Constantes.DOMINIO constant:
mysqldump.exe backup path. If you ever need to change the context root, update Constantes.DOMINIO, set the new context root in the GlassFish deployment descriptor, and rebuild the WAR.