Pulsar-express, a web interface for Apache Pulsar
This story was originally posted on dev.to.
In this article, I am going to present you one of my side project: pulsar-express.
Pulsar-express aims to be a simple web application that allow the users to see informations about their Apache Pulsar clusters.
My initial goal was to provide something very simple (too much, maybe), easy to install, configure and run, and this article will show you these steps.
π Install and run it
There are several ways to use pulsar-express
:
π By cloning the projet and running it locally (see Development
section)
π By running a docker image: docker run -it -p 3000:3000 bbonnin/pulsar-express
- You can set a connection url in the command:
docker run -it -p 3000:3000 -e PE_CONNECTION_URL=http://host.docker.internal:8080 bbonnin/pulsar-express
- Important: the calls to the Pulsar API are done on server side (i.e. from the container), so your Pulsar must be reachable from the container (do not use localhost :)). A solution: you can add
--network=host
to the command line (but, it's only working on Linux...)
π By installing it using npm
If you want to configure connections (to be available to all users), you can:
- Create a json file with the connections:
- and set the env variable
PE_CONFIG_FILE
- Or you can also set a connection URL
π For a detailed explication about the security configuration, checkout the README of the project.
From there, you can connect with your browser to the url above !
π Quick start
If you havenβt defined a connection at startup, the first step is to go the Connections
page and add a new connection. These connections are stored on client side (localstorage of your browser)
Overview
In this page, you can see some basic informations about your clusters.
Clusters
Informations about the clusters (URL, β¦). You can update some informations.
Tenants
Informations about the tenants.
In this page, you can also create a tenant.
Namespaces
Informations about the namespaces:
In this page, you can also create a namespace.
Topics
Informations about the topics:
In this page, you can also create a topic.
Details about a topic:
Functions
Informations about the functions:
Details about a function:
π» Development
The repository of the app is: https://github.com/bbonnin/pulsar-express.
This app has been developed with Nuxt.js.
Here the main commands for the development steps:
For detailed explanation on how things work, checkout Nuxt.js docs.
For Docker:
- Build:
npm run docker-build
- Test locally:
npm run docker-run
- Tag:
docker tag pulsar-express USER/pulsar-express:VERSION
- Publish:
docker push USER/pulsar-express:VERSION
π§ Conclusion
There is still a lot to be done to get a fully functional application.
If you are interested in the project, feel free to participate in the development of the application π π