Monitor Microgateway Licenses

A valid license is required unless Airlock Microgateway is used in the Community Edition. To use premium features, request an evaluation license or obtain a premium license from your sales partner. The available editions are compared in Editions.

License validity and behavior

The possible license states and their effects are described in the following table.

License validity

Definition

Microgateway Engine behavior

Valid license

  • Valid license (metric microgateway_license_valid = 1).
  • Traffic is secured according to the configuration.

Expired license

  • The license is expired (metric microgateway_license_valid = 0) as soon as the license expiry timestamp metric value is reached. Use microgateway_license_expiry_timestamp_seconds to monitor the license expiry date.
  • Gateway pods created before the license expiry timestamp run normally.
  • Gateway pods created after the license expiry timestamp block all traffic.

Insufficient license

  • ContentSecurity is configured as secured in the GatewayParameters, but it is not covered by the licensed modules.
  • All traffic is blocked.
  • A policy is configured for an HTTPRoute, but the required module is not licensed.
  • Examples

    • An AccessControlPolicy is configured for an HTTPRoute, but the auth module is not licensed.
    • ContentResponsePolicy, ICAPPolicy, or similar policies are configured for an HTTPRoute, but the filter module is not licensed.
  • The policy is rejected.
  • Traffic for the affected HTTPRoute is blocked.

Invalid license

  • Invalid license (metric microgateway_license_valid = 0).
  • All traffic is blocked.
 
Notice

If no license is provided, Airlock Microgateway operates in Community Edition mode. If premium features are configured, the resulting license state is Insufficient license.

Monitor the licensed throughput

The Airlock Microgateway premium license model is trust-based and applies to calendar-based monthly request rates. You should upgrade your license if the number of requests exceeds the licensed count.

Monitoring request throughput is not required in the following cases:

  • Community Edition: The available features can be used free of charge and without restriction.
  • Evaluation license: The licensed throughput limit is enforced automatically.
 
Info

Due to the default Prometheus storage retention, metrics data might not cover the required time range. Therefore, we recommend setting up a dedicated Prometheus deployment with a higher storage retention for metrics that monitor license throughput.

Microgateway license dashboard

The easiest way to get an estimate of the license relevant request count, use the Microgateway licensing dashboard, which is created and maintained by Airlock. For more information see Grafana Dashboards for Metrics and Log Visualization.

With your own tooling

To monitor license usage with your own monitoring stack, use the following Prometheus metrics exposed by the Microgateway Operator:

  • microgateway_license_http_rq_total (counter): Total number of license relevant HTTP requests processed. To determine license usage, calculate the increase of the number of requests within a calendar month.
  • microgateway_license_max_rq_count_per_month (gauge): The licensed request count per month.