GlassFish

GlassFish

GlassFish is an open-source Jakarta EE (formerly Java EE) application server that serves as the reference implementation of the Jakarta EE specifications.

GlassFish is the reference implementation of Java EE and as such supports Enterprise JavaBeans, JPA, JavaServer Faces, JMS, RMI, JavaServer Pages, servlets, etc. This allows developers to create enterprise applications that are portable and scalable, and that integrate with legacy technologies. Optional components can also be installed for additional services.

Built on a modular kernel powered by OSGi, GlassFish runs straight on top of the Apache Felix implementation. It also runs with Equinox OSGi or Knopflerfish OSGi runtimes. HK2 abstracts the OSGi module system to provide components, which can also be viewed as services. Such services can be discovered and injected at runtime.

GlassFish is based on source code released by Sun and Oracle Corporation's TopLink persistence system. It uses a derivative of Apache Tomcat as the servlet container for serving Web content, with an added component called Grizzly which uses Java New I/O (NIO) for scalability and speed.

Why is GlassFish Important?

GlassFish is special because it is the: Reference Implementation (RI) of Jakarta EE

That means:

• When a new Jakarta EE version is released
• GlassFish is the first server to support it

Other servers like:

• WildFly
• Apache TomEE

follow later or implement compatible features

Key Features of GlassFish

Full Jakarta EE Support

Includes:

• Servlets, JSP
• CDI (Dependency Injection)
• JPA (Persistence)
• JMS (Messaging)
• JAX-RS (REST APIs)
• JTA (Transactions)

Reference Implementation

• Ensures standards compliance
• Used for testing Jakarta EE specs

Built-in Admin Console

• Web-based UI
• Easy configuration

Hot Deployment

Deploy apps without restarting server

Clustering Support

• Multiple instances
• Load balancing

Architecture of GlassFish

GlassFish has a modular architecture built around:

1. OSGi-based modules

Dynamic loading/unloading

2. Grizzly Web Server

Handles HTTP requests

3. HK2 Dependency Injection

Internal service management

Advantages

Always Up-to-Date with Standards

First to support new Jakarta EE versions.

Full Enterprise Stack

Everything included out-of-the-box.

Good for Learning

Ideal for understanding Jakarta EE.

Stable Reference Behavior

Predictable implementation of specs.

Disadvantages

Not Always Production-Optimized

Focus is correctness, not performance tuning.

Slower Innovation vs Competitors

Compared to modern frameworks.

Smaller Community (Today)

Less popular than:

• Spring Boot

Heavier Than Lightweight Options

Compared to:

• Quarkus

Contents related to 'GlassFish'

TomEE
TomEE
Geronimo
Geronimo
WildFly (JBoss)
WildFly (JBoss)
WebLogic
WebLogic
in-VM
in-VM