Generated by GPT-5-mini| Jakarta Server Pages | |
|---|---|
| Name | Jakarta Server Pages |
| Developer | Eclipse Foundation |
| Released | 1999 |
| Programming language | Java (programming language) |
| Operating system | Cross-platform software |
| Platform | Java Platform, Enterprise Edition |
| License | Eclipse Public License |
Jakarta Server Pages is a server-side technology for generating dynamic web content using Java (programming language) and component models from Jakarta EE. It enables separation of presentation and business logic by embedding scripting elements and custom tags into markup processed on Apache Tomcat, Jetty (web server), GlassFish, WildFly, IBM WebSphere, and Oracle WebLogic Server. Originating from early web templating efforts, it remains integrated with standards from Java Community Process and implementations governed by the Eclipse Foundation.
Jakarta Server Pages provides a template mechanism that combines static markup with dynamic constructs to produce responses for Hypertext Transfer Protocol requests handled by Servlet (Java) containers such as Apache Tomcat, Jetty (web server), GlassFish, WildFly, IBM WebSphere, and Oracle WebLogic Server. Designed to interoperate with JavaServer Faces, Expression Language, Java Persistence API, Java Transaction API, and Jakarta RESTful Web Services, it supports inclusion of reusable components via tag libraries from projects like Jakarta Tag Libraries and tools such as Apache Struts and Spring Framework. JSP pages are compiled into servlets, leveraging the Java Virtual Machine for execution across Linux, Microsoft Windows, macOS, and cloud platforms like Amazon Web Services, Microsoft Azure, and Google Cloud Platform.
JSP emerged in the context of web application frameworks and servlet standards created by the Apache Software Foundation and the Sun Microsystems era of Java (programming language). Early milestones include integration with Servlet (Java) specification efforts overseen by the Java Community Process and adoption by servlet containers such as Apache Tomcat. Over time, the technology evolved through stewardship by Eclipse Foundation and inclusion in Jakarta EE platform releases, with related specifications like Expression Language and tag library standardization influenced by projects including Jakarta Taglibs and frameworks like Apache Struts, Spring Framework, Hibernate, and MyFaces. Major ecosystem events involved collaboration among vendors such as Oracle Corporation, Red Hat, IBM, Eclipse Foundation, BEA Systems, and contributors from enterprises like Google and Microsoft.
The JSP architecture relies on interactions among web clients using Hypertext Transfer Protocol, web containers that implement the Servlet (Java) specification, and backend services conforming to Jakarta EE APIs such as Jakarta Servlet, Jakarta Expression Language, Jakarta Persistence API, and Jakarta RESTful Web Services. Core components include JSP pages, JSP tag libraries (simple and tag file-based), JSP fragments, and the generated servlet classes managed by containers like Apache Tomcat and GlassFish. Toolchain integrations involve build systems such as Apache Maven, Gradle (software), continuous integration servers like Jenkins (software), Travis CI, and GitHub Actions enabling deployments to application servers including WildFly, IBM WebSphere, and Oracle WebLogic Server.
JSP uses syntactic constructs that map to Java (programming language) code and standardized tag libraries. Key syntactic forms include directives, scriptlets, expressions, and declarations, and interoperable features include the Jakarta Expression Language and Tag Library Descriptor files, which are used by libraries like Jakarta Taglibs, JavaServer Faces, Apache Struts, and third-party collections from vendors such as Oracle Corporation and Red Hat. Community-driven tag libraries and frameworks—examples include Apache Taglibs, Jakarta Server Faces, Spring Web, Tiles (web template system), and DisplayTag—provide components for internationalization with standards like ICU (software) and integration with Jakarta Validation and Jakarta Transactions.
At build or first-request time, JSP pages are translated into Servlet (Java) classes compiled to bytecode executed on the Java Virtual Machine within containers like Apache Tomcat, Jetty (web server), GlassFish, WildFly, IBM WebSphere, and Oracle WebLogic Server. Class loaders and deployment descriptors from Jakarta EE influence lifecycle management alongside tools such as JRebel and profilers from YourKit and VisualVM. Runtime behavior involves request dispatching, session management with specifications like Jakarta Session Tracking, and integration with persistence layers such as Hibernate and EclipseLink for database access via Jakarta Persistence API. Build automation with Apache Maven or Gradle (software) and container orchestration on platforms like Kubernetes and Docker affects compilation pipelines and runtime scaling.
Secure use of server-side templates requires mitigating risks identified in standards and security guidance from organizations like Open Web Application Security Project and vendor advisories from Oracle Corporation, Red Hat, and IBM. Best practices include avoiding scriptlets in favor of Jakarta Expression Language and MVC patterns implemented with frameworks such as Spring Framework and Jakarta Server Faces, validating inputs with Jakarta Validation, securing transports with Transport Layer Security, and managing authentication and authorization through Jakarta Security or integrations with OAuth 2.0, OpenID Connect, SAML, and identity providers like Keycloak and Okta. Static analysis tools from SonarSource, dependency management via Maven Central, and container hardening guidelines from CIS complement runtime configurations for Content Security Policy and session protection.
JSP technology has been adopted widely in enterprise Java ecosystems and is implemented by servlet containers and application servers including Apache Tomcat, Jetty (web server), GlassFish, WildFly, IBM WebSphere, Oracle WebLogic Server, and cloud platforms like Amazon Web Services, Google Cloud Platform, and Microsoft Azure. Frameworks that build on or interoperate with JSP include Apache Struts, Spring Framework, Jakarta Server Faces, Apache Wicket, and legacy systems from BEA Systems and Sun Microsystems. Tooling ecosystems involve IDEs such as Eclipse (software), IntelliJ IDEA, and NetBeans, build systems like Apache Maven and Gradle (software), and CI/CD platforms including Jenkins (software), GitLab CI, and GitHub Actions. The specification and ecosystem continue to be shaped by organizations including Eclipse Foundation, Jakarta EE, Java Community Process, and contributors from Oracle Corporation, Red Hat, IBM, Google, and the broader open source community.