Hello Michael,

The use case we had was for a kubernetes HPA based on a job load metrics.

Basically, the infrastructure deploys a number of instances that depends on the number of jobs that are planned (so that asychronous jobs doesn't pile up and get problematic).

To do so, kubernetes uses a custom metric provided by a prometheus implementation that runs a query every few seconds.

This is the example i'm thinking about. Beeing able to see the load of current jobs on each instance (on a multi instance setup), see history of workloads overtime, etc.

I hope I am clear enough in my explanation, and this is only an example.

Regards,

Gaetan

On 8/6/25 13:22, Michael Brohl wrote:
Hi Gaetan,

from the given references, it is not quite clear for me what this plugin would provide for the project.

Can you elaborate some more about it?

Besides this, I wonder if it is really necessarry to start an embedded http server. I assume it should be possible to access the ressources by an independent http server also?

In most of the (productive) environments I am aware of, you have a http server in front of the OFBiz Tomcat anyway. If the ressources are accessible by it, we simply need some documentation for a virtual host configuration.

Thanks and regards,

Michael Brohl

ecomify GmbH - www.ecomify.de



Am 05.08.25 um 17:31 schrieb gaetan.chaboussie:
Hello community.
I'm getting back to working on the ticket that caused the Jakarta migration[1] in the first place.
With this comes a question that i'm asking myself.
The library i plan to use[2] ships with a lightweight HttpServer of its own, and this server comes with the "metrics" url embedded[3]. I'm not a fan of starting another HttpServer in OFBiz, knowing that Tomcat is already running. But the PrometheusExposer (name is still work in progress) would be a plugin, and thus can't access the tomcat instance to enable ports. This would be solvable in documentation of the plugin, indicating the lines to add to the catalina ofbiz component to open the port 9400 (prometheus default).

But this still leaves the problem of the "metrics" url, and of the prometheus request handler, that should be an other handler added in the plugin.

To sum up my question, should I be looking for a full integration of the library, with the implementation of a custom RequestHandler, the oppening of an additional Tomcat port, and probably more, or would the fact of setting up a lightweight HttpServer in the plugin (that would run parallel to tomcat) be acceptable ?

Thanks and regards.
Gaetan

[1] https://issues.apache.org/jira/projects/OFBIZ/issues/OFBIZ-12990

[2] https://prometheus.github.io/client_java//

[3] https://prometheus.github.io/client_java/exporters/httpserver/

Reply via email to