Programming Jakarta Servlets

A Servlet is a web based component, managed by a container, that generates dynamic content. Currently, the latest release of Jakarta Servlets is 5.0 (September 7, 2020). Jakarta Servlet version 5.0 is only a change of namespaces. Thus, migrating a Servlet 4.0 project to Servlet 5.0 and above, requires the replacement of the namespace javax.* … Read more

WildFly CLI Tech Tip #1: How to read WildFly System Properties

Here is a new section for WildFly CLI gurus. In the first tip we will learn how to gather all System Properties which are available in WildFly using the CLI. You might be surprised to see that WidFly System Properties are not available through the /system-property path. For example, if you are looking for the … Read more

Categories CLI

Messaging with Quarkus – part one: JMS Messaging

Quarkus includes several options for sending and consuming aysnchronous messages. In this two-parts tutorial we will learn how to send messages using the JMS API, which is well-known to Java Enterprise developers. In the next tutorial we will check out how to use Reactive Messaging to handle messages through the mediation of a Bus. JMS … Read more

How to develop CXF Web services with JBoss

Please note, this article has been written for JBoss AS 5 so the content might not be suitable for the latest version of the application server.
For WildFly users, we recommend checking this article: SOAP Web services on WildFly made simple

JBoss AS 5 ships with Apache CXF web services implementation. In this tutorial we will show how to create a simple Web service endpoint and how to deploy and test it with a client.

Read more

Using WildFly core as management interface

WildFly core is the core runtime that is used by the Wildfly application server. It provides some minimal functionalities such as the classloader, JMX Api and the security framework (Elytron). Besides it, you can use it as Management endpoint. In this tutorial we will learn how to install it and use it as Management interface … Read more

Getting started with Camel 3

Let’s have a look at what’s new in Camel 3 with an example project which shows how to run a Camel 3 standalone via the built-in Main class. This example also demonstrates how you can configure the Camel application via Camel built-in dependency-injection that supports binding via the @BindToRegistry and @PropertyInject annotations. Apache Camel 3 … Read more

How to receive transaction callbacks for EJB and CDI beans

The JTA API gives a chance to receive callbacks on the event of a finishing transaction. As per specification, the transaction manager announces the even of beforeCompletion and afterCompletion which are defined by the interface javax.transaction.Synchronization. More in detail: beforeCompletion callback is invoked at time the transaction manager starts to commit the global transaction. The … Read more

Debugging JPA in WildFly

In order to debug the Persistence Service in WildFly you can increase the org.jboss.as.jpa logging in order to gather the following information: INFO – will log information when persistence.xml has been parsed, when the persistence.xml has been deployed and when the persistence unit service has been stopped DEBUG – will inform you when Entity Managers … Read more

From Tomcat Valves to Undertow Handlers in a nutshell

Undertow doesn’t support the older JBoss Web valves, however most of them can be easily migrated to Undertow handlers. Here is a list of those valves and their corresponding Undertow handler: Valve Handler org.apache.catalina.valves.AccessLogValve io.undertow.server.handlers.accesslog.AccessLogHandler org.apache.catalina.valves.ExtendedAccessLogValve io.undertow.server.handlers.accesslog.AccessLogHandler org.apache.catalina.valves.RequestDumperValve io.undertow.server.handlers.RequestDumpingHandler org.apache.catalina.valves.RewriteValve io.undertow.server.handlers.SetAttributeHandler org.apache.catalina.valves.RemoteHostValve io.undertow.server.handlers.AccessControlListHandler org.apache.catalina.valves.RemoteAddrValve io.undertow.server.handlers.IPAddressAccessControlHandler org.apache.catalina.valves.RemoteIpValve io.undertow.server.handlers.ProxyPeerAddressHandler org.apache.catalina.valves.StuckThreadDetectionValve io.undertow.server.handlers.StuckThreadDetectionHandler org.apache.catalina.valves.CrawlerSessionManagerValve io.undertow.servlet.handlers.CrawlerSessionManagerHandler It is possible to … Read more

Writing a custom Undertow Handler

In this quick quick tutorial we will learn how to add a custom Handler to Undertow and then we will install it on WildFly as a module. The main Undertow functionality is provided by io.undertow.server.HttpHandler instances. These handlers can be chained together to form a complete server. In this example, we will add a TimedHandler … Read more