![]() LGauge.SetDuration( // set value to duration of method execution LGauge.SetTo( 123) // set value directly to 123 For example, do not use a counter for the number of currently running processes instead use a gauge.īegin var LGauge := TGauge.Create( 'sample ', 'Description of this gauge ') For example, you can use a counter to represent the number of requests served, tasks completed, or errors.ĭo not use a counter to expose a value that can decrease. CounterĪ counter is a cumulative metric that represents a single monotonically increasing counter whose value can only increase or be reset to zero on restart. ![]() Prometheus Delphi Client supports the following metric types. You can export your metrics calling the text based exporter or making use of a ready to use middleware that targets your favourite Delphi Web framework (see Middlewares section below for details). Update your metrics as needed calling the appropriate methods you can find on collector instance depending on the classes they are based to. Register your metrics inside the default collector registry or in a registry of your own for subsequent handling and exportation. Installation is done using the boss install command:ĭefine the metrics you want to track using the appropriate classes (see below). To get started with the Prometheus Delphi Client library, you need to follow these steps. Custom Collectors: the library allows you to define custom collectors that can be used to collect metrics from any source.Labels: these are key-value pairs that allow you to add additional context to your metrics.Basic metrics: the library allows you to define some basic metrics supported by Prometheus to track some relevant values in your application, like the number of times an event has occured or the current amount of allocated memory and so on.The Prometheus Delphi Client library offers a range of features that make it a powerful and flexible tool for monitoring Delphi applications using Prometheus.īy using the library, you can gain valuable insights into the performance and behavior of your Delphi applications and make data-driven decisions to improve them. Here we will discuss the client library for Prometheus written for Embarcadero Delphi. To use Prometheus effectively, you need a client library implemented in your favorite programming language that can be integrated into your applications to expose the relevant metrics to the Prometheus server. It provides a powerful system for collecting and analyzing metrics from various sources, including applications, servers, and other systems. Prometheus is a popular open-source monitoring tool that is widely used in modern software environments. The library also supports Prometheus' text based exposition format, that can be configured and made available via an HTTP endpoint on your Web application's instance using specific middlewares or directly calling the text exporter. It allows you to instrument your Delphi code with custom metrics and provides some built-in and ready to use metrics. The Prometheus Delphi Client library is a set of classes that allow you to instrument your Delphi applications with Prometheus metrics. This is a Delphi client library for Prometheus, similar to libraries created for other languages.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |