-
Notifications
You must be signed in to change notification settings - Fork 394
Blog on Quarkus JDiameter Extension #2082
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,7 +22,7 @@ sannegrinovero: | |
leydenquarkus: | ||
name: "Maria Arias de Reyna Dominguez, Andrew Dinn, Sanne Grinovero" | ||
job_title: "OpenJDK and Quarkus team working on Project Leyden at Red Hat" | ||
bio: "Maria Arias de Reyna Dominguez is a Java Champion and member of the OpenJDK team at Red Hat; Andrew Dinn is a Distinguished Engineer at Red Hat, and Architect responsible for OpenJDK and GraalVM; Sanne Grinovero is a Java Champion, founding member of the Quarkus project and Architect in the middleware group at Red Hat." | ||
bio: "Maria Arias de Reyna Dominguez is a Java Champion and member of the OpenJDK team at Red Hat; Andrew Dinn is a Distinguished Engineer at Red Hat, and Architect responsible for OpenJDK and GraalVM; Sanne Grinovero is a Java Champion, founding member of the Quarkus project and Architect in the middleware group at Red Hat." | ||
dandreadis: | ||
name: "Dimitris Andreadis" | ||
email: "[email protected]" | ||
|
@@ -559,3 +559,10 @@ karesti: | |
job_title: "Engineer (Software)" | ||
twitter: "karesti" | ||
bio: "Software Engineer at Red Hat and Infinispan team member." | ||
eddiecarpenter: | ||
name: "Eddie Carpenter" | ||
email: "[email protected]" | ||
emailhash: "1eafb77e5daee9aba696f7c23de0bc86" | ||
job_title: "Principal Software Engineer" | ||
twitter: "" | ||
bio: "Principal Software Engineer and IT Executive" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
--- | ||
layout: post | ||
title: 'Revolutionising Telecom Microservice - Modernising JDiameter with Quarkus' | ||
date: 2024-08-19 | ||
tags: user-story jdiameter | ||
synopsis: My journey of with JDiameter and Quarkus | ||
author: eddiecarpenter | ||
--- | ||
:imagesdir: /assets/images/posts/quarkus-jdiameter-intro | ||
|
||
image::quarkus-jdiameter-intro.png[],align="center"] | ||
= Introduction | ||
|
||
The Diameter protocol serves as a cornerstone in any modern telecommunication backend, providing authentication, authorisation, and accounting (AAA) services in 3G, IMS, 4G, and 5G networks. Several vendors offer commercially licensed Diameter stacks, most of which are written in C++. As a result, many in the Java world have turned to the open-source RestComm JDiameter stack. | ||
|
||
Developed in the early 2010s, JDiameter has not received any updates in the last seven years. A major challenge with JDiameter is its reliance on outdated dependencies—some with known Common Vulnerabilities and Exposures (CVEs)—and others that are deprecated or no longer supported. Additionally, JDiameter was written in Java 1.7, which restricts the use of modern advancements in the Java language, such as virtual threading. | ||
|
||
With the shift towards microservices in telecommunications, many organisations now develop solutions that are deployed and managed using platforms like Kubernetes and OpenShift. In the Java ecosystem, developers have several microservices frameworks to choose from, with the major ones being Spring Boot, Micronaut, and my preferred choice, Quarkus. | ||
|
||
Over the past seven years, I have primarily developed solutions for charging and billing subscribers in prepaid mobile networks, including writing both a Diameter Routing Agent (DRA) and an Online Charging System (OCS). In both instances, I used Quarkus as the microservices framework and JDiameter as the Diameter stack—with much frustration, I must add. | ||
|
||
The solutions we developed were functional, but they felt more like a Quarkus application with a JDiameter sidecar. The Diameter stack operated independently, without leveraging the benefits offered by the Quarkus framework. | ||
|
||
= Quarkus JDiameter Extension | ||
|
||
Eventually, my frustration with the sidecar approach of integrating JDiameter with Quarkus led me to develop a solution that would allow the two to work more harmoniously. This initiative resulted in the creation of the Quarkus JDiameter extension. | ||
|
||
As mentioned earlier, the RestComm JDiameter stack had been neglected and was in dire need of some attention. My first step was to modernise the JDiameter stack by removing deprecated dependencies and updating the outdated ones to their latest versions. | ||
|
||
Two key changes were made to the stack. The first was removing Pico containers—an outdated dependency injection framework from the pre-Java EE era—and the second was replacing the concurrency logic from the old Thread Group model with the more modern Thread Pool model. With the introduction of thread pooling, the Diameter stack can now utilise virtual threading! | ||
|
||
The next challenge was to develop a Quarkus extension to integrate the Diameter stack into the Quarkus framework. I had three main objectives with this extension: | ||
|
||
. *Simplified Configuration*: Moving the configuration to the "application.properties“ file to make the stack easier to configure. | ||
. *Dependency Injection*: Enabling dependency injection of Diameter stacks and configuration into a scoped service. | ||
. *Interceptor Service Framework*: Creating an interceptor service framework for a more straightforward implementation of Diameter applications. | ||
|
||
The Quarkus JDiameter stack has been released and is now part of Quarkiverse Hub. You can find it at link:https://github.com/quarkiverse/quarkus-jdiameter[Quarkiverse Hub]. Documentation for the stack is available at link:https://docs.quarkiverse.io/quarkus-jdiameter/2.0.0/index.html[Quarkus JDiameter Documentation]. | ||
|
||
= Conclusion | ||
|
||
There is still considerable potential for tighter integration of the JDiameter stack into the Quarkus framework. A future project could involve exposing the statistics collected in the stack via the Quarkus MicroProfile Metrics interface. | ||
|
||
If you’ve been frustrated with integrating JDiameter in a microservice environment, as I was, give the Quarkus JDiameter extension a try! |
Binary file added
BIN
+2.95 MB
assets/images/posts/quarkus-jdiameter-intro/quarkus-jdiameter-intro.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.