Pierre Squarra


Common Interface Implementation

The Common Interface defines a compatibility layer for peer-to-peer message exchange between various European rail network providers.

GitHub Repository: github.com/squarra/comint

Technologies

The European Union Agency for Railways (ERA) has defined APIs and related specifications using WSDLs and SOAP, making Java a necessity for this project. The key technologies utilized are:

How to run

There are two different modes of running. One for development with all the beauty of quarkus hot reloading and one using kubernetes.

Development with Quarkus hot-reloading

Make sure you have a RabbitMQ container running. You can either use the provided run configuration (rabbitmq) or run this command:

$ docker run -d --name rabbitmq -p 5672:5672 -p 15672:15672 rabbitmq:management

This will expose the AMQP port (5672) as well as the RabbitMQ management console (15672).

Now you can start the Quarkus application using the provided run configuration (quarkus) or this command:

./mvnw quarkus:dev

Kubernetes

This is done using minikube and kubectl. You can also use Docker Desktop or any other kubernetes cluster for it.

  1. Start minikube:
 minikube start
  1. Point your terminal to use Minikube’s Docker daemon (this needs to be done in each new terminal window you want to build images in):
 eval $(minikube docker-env)
  1. Build your Quarkus application image in Minikube’s environment (from project root):
 docker build -t quarkus-app:latest .
  1. Apply the Kubernetes configurations (development):
kubectl apply -k kubernetes/overlays/development/
  1. Check if everything is starting up properly:
kubectl get pods
kubectl get services
  1. Wait for all pods to show “Running” status. You can watch them with:
kubectl get pods --watch
  1. To access your services, get the URLs:
minikube service rabbitmq --url
minikube service quarkus-app --url

When you’re done working and want to shut everything down:

kubectl delete -k kubernetes/ .
minikube stop

To deploy production environment:

kubectl apply -k kubernetes/overlays/production