SiCom is a multi-module Maven project that compiles four modules in dependency order —Documentation Index
Fetch the complete documentation index at: https://mintlify.com/dinogamer089/SiCom/llms.txt
Use this file to discover all available pages before exploring further.
entidad → persistencia → negocio → vista — and packages the result as a single WAR file (vista.war). The steps below take you from a fresh clone to a running instance on Apache Tomcat 10.1.
Verify Java 21 Is Active
The parent The output must report
pom.xml sets maven.compiler.source and maven.compiler.target to 21. Using an older JDK will cause a compilation error.21.x. If you manage multiple JDK installations with a tool such as SDKMAN or jenv, activate the Java 21 distribution before proceeding.Build All Modules from the Reactor Root
Run the standard Maven lifecycle from the repository root. Maven resolves the The build sequence is:
<modules> declaration in the parent pom.xml and builds the modules in the correct dependency order.- entidad — JPA entity classes; packaged as
entidad-1.0-SNAPSHOT.jar - persistencia — DAOs,
persistence.xml, HikariCP/Hibernate configuration; packaged aspersistencia-1.0-SNAPSHOT.jar - negocio — Business-logic façade beans; packaged as
negocio-1.0-SNAPSHOT.jar - vista — JSF/PrimeFaces web layer; packages everything into
vista.war
BUILD SUCCESS and all four modules reporting [INFO] BUILD SUCCESS.Locate the Deployable WAR
After the build completes, the deployable archive is at:The final name is fixed to
vista by <finalName>vista</finalName> in vista/pom.xml, so the context path in the browser will always be /vista.Deploy to Tomcat
Copy the WAR to Tomcat’s Tomcat will explode the WAR automatically on startup. Watch
webapps directory and start the server:$CATALINA_HOME/logs/catalina.out for any PersistenceException messages, which would indicate that the database is not reachable or that the schema validation failed.PrimeFaces Theme
The default theme is saga, set via a<context-param> in web.xml:
lara-light-blue, arya-blue, vela-green) can be substituted without recompiling the project — edit the <param-value> and redeploy.
File Upload Configuration
Two mechanisms work together to support catalogue image uploads:UploadInitListener (config.UploadInitListener) is registered as a ServletContextListener in web.xml and fires during application startup. It relaxes Tomcat’s internal file-count and parameter-count limits by setting system properties:
UploadImageServlet handles POST requests to /upload-image. It reads the imagen multipart part, stores the raw bytes and MIME type in the HTTP session, and returns 204 No Content to the caller:
<multipart-config> in web.xml) rather than the Apache Commons FileUpload library.
Logging
SiCom uses SLF4J 2.0.9 as the logging façade and Logback 1.4.11 as the implementation, both declared invista/pom.xml. Place a logback.xml configuration file in vista/src/main/resources/ to control log levels and appenders. Without an explicit configuration, Logback falls back to its default DEBUG console appender.
JSF development mode:
web.xml sets jakarta.faces.PROJECT_STAGE to Development. In this mode JSF renders additional debug information in the browser (component tree inspection, EL expression errors, etc.) and disables some resource caching. Switch the value to Production before any live deployment to enable resource bundling, suppress debug output, and improve page-load performance: