EnterPrise JavaBeans (EJB) technology is a server-side component that enables rapid and simplified development of distributed, transactional, secure and portable applications. The services provided by the technology remain transparent to developers and elminate the tedious and often error-prone task of adding a lot of boiler plate code which would otherwise be required.
EJB container provides common functionality as out-of-the-box services (e.g. managing application state, storing and retrieving information from a relational database, managing transactions, implementing security, performing asynchronous processing, integrating systems, and so on). EJB components can use them in applications without reinventing a wheel.
JPA allows to store data contained in Java objects into a relational database. The Java Persistence API (JPA) is an object-relational mapping (ORM) technology that enables applications to manage data between Java objects and a relational database in transparent way. One can apply JPA in a project by creating and configuring a set of Java classes (entities) that mirror a data model. Such an application can then access these entities as though it were directly accessing the database.
There are various benefits of using JPA in projects:
- JPA has Java Persistence Query Language (JPQL) – its own rich, SQL-like query language for static and dynamic queries. It lets the application to stay independent of different database vendors.
- Designer and programmers can avoid the task of writing low-level, verbose and error-prone JDBC/SQL code.
- JPA transparently provides services for data caching and performance optimization.
JAX-RS (Java API for RESTful Web Services)
JAX-RS is a specification of an application programming interface (API) of the Java programming language, which provides support in creating web services according to the Representational State Transfer (REST) architectural pattern.
A functionality described in the specification was developed by a consortium of companies around Sun Microsystems and other independent parties under the Java Community Process and adopted in Java Specification Request 311. Like other programming interfaces of JEE, JAX-RS uses annotations in order to simplify a development and deployment of web service clients and service endpoints.
The reference implementation of JAX-RS is provided by an open source project called Jersey. Other implementations of JAX-RS are among others: Restlet, JBoss’ Rest Easy, Apache Wink and a JAX-RS extension of Apache CXF.
JAX-WS (Java API for XML Web Services)
JAX-WS is a Java API for creating Web services. Client and service endpoint communicate via SOAP messages. JAX-WS is protocol and transport independent. By default, however, SOAP 1.1 and HTTP is used.
In order to process a data correctly, the XML data types must be converted into Java-compliant data types. This task is delegated to JAXB (Java Architecture for XML Binding). Thus, the XML processing is essentially hidden from the programmer.
In this approach there are two different ways to build service endpoints: Code First (Bottom Up) on POJOs and Contract First (Top Down) via WSDL.
Java Message Service (JMS) is an application programming interface (API) aiming for a Message Oriented Middleware (MOM) to send and receive messages from a client that is written in Java. JMS has a goal to be loosely coupled, to allow reliable and asynchronous communication between components of a distributed application. There are two different approaches for sending messages: using message queue for point-to-point connection or using dispatch system (topic) for publish-subscribe communication.
To use JMS, a JMS provider is required that manages the topics, queues and sessions. The most popular tools in this category include ActiveMQ, RabbitMQ, Websphere MQ.
A WebSocket protocol is based on TCP network protocol, which was designed to establish a bidirectional connection between a Web application and a WebSocket server or a Web server that also supports WebSockets. While a pure HTTP connection requires for any response a previous request from a client, for a WebSocket protocol it’s sufficient when the client opens the connection. A server can then use this open connection and deliver new information to the client, without waiting for a new connection from the client.
JavaServer Faces (JSF) is a framework standard for a development of graphical user interfaces for web applications. Based on Servlets and JSP technology, JSF is one of the web technologies of Java Enterprise Edition.
It is designed to significantly ease the burden of writing and maintaining applications that run on a Java application server and render their UIs back to a target client.
JSF provides ease-of-use in the following ways:
- Makes it easy to construct a UI from a set of reusable UI components.
- Simplifies migration of application data to and from the UI.
- Helps manage UI state across server requests.
- Provides a simple model for wiring client-generated events to server-side application code.
- Allows custom UI components to be easily built and re-used.
It’s also worth to emphasize that starting from Q2’14, a close integration between AngularJS and Kendo UI is officially supported.
An example of Kendo UI view:
AngularJS is based on MVVM (Model View ViewModel) pattern. It’s an architectural pattern based on MVC and MVP, which attempts to more clearly separate the development of user-interfaces (UI) from that of the business logic and behaviour in an application. This facilitates UI and development work occurring almost simultaneously within the same codebase. Frontend developers write bindings to the ViewModel within their document markup (HTML), where the Model and ViewModel are maintained by developers working on the logic for the application.
The great power of AngularJS is also based on its testing facilities. As applications grow in size and complexity, it becomes unrealistic to rely on manual testing to verify the correctness of new features, catch bugs and notice regressions. Unit tests are the first line of defense for catching bugs, but sometimes issues come up with integration between components which can’t be captured in a unit test. End to end tests are made to find these problems. E2E tests within AngularJS are based on Protractor tool, which is a test runner to simulate user interactions that help to verify the health of Angular application.
AngularJS main features:
Grails gives us a facility to build a backend of application in fast and robust way. Grails was initially named Groovy on Grails because it was inspired on a Ruby on Rails framework. It is an Open Source, full stack, web application framework for the JVM. It takes advantage of the Groovy programming language and convention over configuration to provide a productive and stream-lined development experience. Grails, along with its facility to develop test driven, is a killer combination for rapidly developing web applications.
Grails is actually built on Groovy which gives the immediate benefit of being more productive. The Groovy syntax is much terser than Java, it’s much easier to do things in one line of Groovy code that would take you several in Java. At the same time Groovy has the capability to work with Java seamlessly.
The ideas included in Grails are innovative, but Grails itself is built on several mature and popular development solutions and frameworks, e.g. Spring and Hibernate. Thanks to this we can be sure to base our application on a steady foundation, being able to develop our apps rapidly at the same time.
Grails has a huge number of plugins which have been contributed by the core development team and other Grails application developers. In case we want to integrate an existing framework or use an API, we often find a plugin that makes the integration much easier.
Grails scaffolding capabilities let us create a base of a new app within few minutes. Dynamic scaffolding allow us to generate an user interface on the base of a domain class with the operations like Create, Read, Update and Delete (CRUD).
PostgreSQL is an advanced Open Source database specifically designed for high-volume requirements. PostgreSQL provides new and unique functionality that goes way beyond the traditional relational-database feature set. It has more than 15 years of active development and a proven architecture that has earned it a strong reputation for reliability, data integrity, and correctness.
PostgreSQL boasts sophisticated features such as Multi-Version Concurrency Control (MVCC), point in time recovery, tablespaces, asynchronous replication, nested transactions (savepoints), online/hot backups, a sophisticated query planner/optimizer, and write ahead logging for fault tolerance. It supports international character sets, multibyte character encodings, Unicode, and it is locale-aware for sorting, case-sensitivity, and formatting. It is highly scalable both in the sheer quantity of data it can manage and in the number of concurrent users it can accommodate. There are active PostgreSQL systems in production environments that manage in excess of 4 terabytes of data.
PostgreSQL prides itself in standards compliance. Its SQL implementation strongly conforms to the ANSI-SQL:2008 standard. It has full support for subqueries (including subselects in the FROM clause), read-committed and serializable transaction isolation levels. And while PostgreSQL has a fully relational system catalog which itself supports multiple schemas per database, its catalog is also accessible through the Information Schema as defined in the SQL standard.
It also has a host of extensions and advanced features. Among the conveniences are auto-increment columns through sequences, and LIMIT/OFFSET allowing the return of partial result sets. PostgreSQL supports compound, unique, partial, and functional indexes which can use any of its B-tree, R-tree, hash, or GiST storage methods.
Other advanced features include table inheritance, a rules systems, and database events. Table inheritance puts an object oriented slant on table creation, allowing database designers to derive new tables from other tables, treating them as base classes. Even better, PostgreSQL supports both single and multiple inheritance in this manner.
PostgreSQL runs stored procedures in more than a dozen programming languages, including Java, Perl, Python, Ruby, Tcl, C/C++, and its own PL/pgSQL, which is similar to Oracle’s PL/SQL. Included with its standard function library are hundreds of built-in functions that range from basic math and string operations to cryptography and Oracle compatibility.