- [docker] Correctly build and tag base and full images.
- [docker] Remove unnecessary
devgroup dependencies from image.
- [docker] Fix build/release action.
- Support disabling database connection pooling (by settings
size: 0for the pool). - Use
apschedulerfor scheduling periodic queries. - Use
uvfor dependencies pinning and installation. - [snap] Drop support for snap package.
- Note:
This release introduces a few breaking changes from the 4.x series, specifically:
[docker] Since
uvis used in place of plain pip for installing, containers built on top of the base image should useuv pip install [<package>...|-r <requirements_file>]
for installing extra dependencies in the application virtualenv.
Since
apscheduleris used in place ofcroniterfor parsing cron-like schedule expressions, there might be difference in the format. Please refer to the apscheduler documentation for details. This switch was required sincecroniteris no longer maintained.
- [docker] Fix arm64 Docker image build
- [github] Cleanup and simplify workflows
- Improve schedule validation in schema
- [github] Add Python 3.14 to CI workflows
- [docker] Add base docker image (as
X.Y.Z-base) without any builtin database engine. It can be used to build custom images with only specific engines to keep image size small.
- Add connection pooling, supporting specifying how many connections can be
used for each database entry (via the
connection-poolsection in thedatabaseconfig). - [docker] Use
pymssqlinstead of PyODBC for MS SQL Server connection. - [docker] Use
oracledbinstead ofcx-Oraclefor Oracle connection. - Report a query error and log the error if the query returns invalid values (#138).
- Switch YAML configuration parsing and validation to Pydantic.
- Import code for periodic calls from
toolrack. - Integration tests improvements.
- Update dependencies.
- Note:
This release introduces a few breaking changes from the 3.x series, specifically:
- The
keep-connectedflag indatabaseentries has been removed, since connections are now managed automatically by the pooling. - The
autocommitflag indatabaseentries has been removed, since queries are now always run in a transaction. - The
env:andfile:prefixes for DSNs string form have been replaced by the corresponding tags. - [docker] Due to the change to
pymssql, the MS SQL Server connection string dialect must be defined asmssql+pymssql://(as SQLAlchmy would otherwise default topyodbc). - [docker] Due to the change to
oracledb, the Oracle connection string dialect must be defined asoracle+oracledb://(as SQLAlchmy would otherwise default tocx_oracle, until SQLAlchemy 2.1 is released).
- The
- [docker] Add support for Teradata server.
- [docker] Add multiarch (
amd64andarm64) support. - Add docker-based integration tests.
- Update dependencies.
- Run queries in explicit transactions, deprecate
autocommitflag (#232) - Add builtin
query_intervalmetric. (#225)
- NOTE:
- The
autocommitflag fordatabaseentries is now deprecated and not used anymore. Queries are always run in a separate transaction with explicit commit/rollback. Queries in theconnect-sqlconfig are all run in a single transaction.
- Support passing multiple configuration files (#108).
- Support YAML tags for
env,file, andinclude(#188).
- NOTE:
- The
env:andfile:prefixes for DSNs string form are now deprecated in favor of the corresponding tags, and will be dropped in the next major release.
- Convert all logging to structured (#199).
- Look for
config.yamlconfiguration file by default, configuration file can be optionally specified with--config. - Support passing configuration options via environment variables.
- Support loading
.envfile with environment variables for configuration. - [docker] Run exporter from the
/configdirectory, supporting having.envfile there. - [snap] Run exporter from the
$SNAP_DATAdirectory, supporting having.envfile there.
- NOTE:
This release introduces a few breaking changes from the 2.x series, specifically:
- The
--log-leveloption now takes lowercase names for levels. - The configuration file is no longer a required option, since
config.yamlin the current directory is looked up automatically. If a different file is specified, it should be done as an optional parameter with--config. - Metrics of type
counterare now set by default to values returned by queries. To preserve the old default behavior of incrementing it by the returned value,incrementshould be set totruein the metric configuration.
- The
- Update
prometheus-aioexporterdependency range.
- Switch to SQLAlchemy 2.
- Require Python 3.11.
- [docker] Use Python 3.13 on Debian Bookwork as base image.
- [snap] Rebase on core24.
- Fix columns names in InvalidResultColumnNames being reported the wrong way round (#185).
- Add a metric to track query execution timestamp (#178).
- [docker] Define a volume containing the config file (#158).
- [docker] Add support for ODBC version 17, support alternative versions.
- Switch to ruff for formatting.
- Fix main script (#171).
- Typos fixes in documentation.
- Update dependency to
prometheus-aioexporter2.0. - [snap] Add support for ClickHouse.
- [docker] Add support for ClickHouse.
- Add
incrementflag for counter metrics (#124). - Rework project setup.
- [docker] Add
pymssqlpackage (#133). - [docker] Fix setup for Microsoft repository (#159).
- Test with Python 3.10 in GitHub actions
- Fix tests
- Require Python 3.10.
- [snap] Change base to core22.
- [docker] Use Python 3.10.
- [docker] Base on Debian 11.
- Require
sqlalchemy_aio0.17.0, drop workaround for previous versions (#105).
- Add support for parameters matrix in queries.
- Allow freetext name for databases in config (#99).
- Require Python3.8
- Move creation of async locks and queues after loop setup (#90, #96).
- Update Python project config.
- Document action performed for each query type (#86).
- Support optional
expirationparameter for metrics to clear stale series (#26). - Correctly close the database connection when
keep-connected: falseis used (#81). - Don't connect to all databases at startup, only when the first query is run.
- Workaround missing attributes from AsyncioEngine (#62 and #76).
- Log app version at startup.
- Fix schedule times iterator for scheduled queries (#76).
- [docker] - Fix build.
- Add support reading database DSN from file.
- Add support for specifying database connection details as separate elements.
- [docker] Fix MSSQL support in.
- Add tracebacks for database errors in debug log.
- Add
queryname label for builtin metrics. - Add optional
timeoutoption for queries. - [snap] Add bash completion.
- [snap] Switch to core20 base.
- [docker] Include support for Oracle database.
- Add a
query_latencymetric to track query execution times. This is labeled by database and query name (#46).
- Add support for query schedule (#29).
- [docker] Pass the config file in the command line.
- [snap] Enable IBM DB2 support only on supported architectures (x86_64, ppc64le and s390x).
- [docker] Fix python library paths.
- Add support for disabling query autocommit in database configuration.
- Validate that metric names don't collide with builtin ones.
- Perform database connect/disconnect under lock (#28).
- Add support for queries to run at connection (#31).
- [snap,docker] Support IBM DB2 (#14).
- When validating config, warn about database and metrics that are not used in any query.
- Support extra per-database labels for metrics. All databases must define the same set of labels (#27).
- Don't disable queries failing because of
OperationalErroras it might not be a fatal error (#25).
- Fix validation for entries in the
queriessection for config file. - [snap,docker] Add MSSQL support.
- Support only named parameters (e.g.:
:param) in queries (#21, #24). - Add JSON-schema validation for config file (#23).
- Validate at startup if database engines from DSNs are supported and corresponding modules are available.
- Check that names for queries
parametersmatch the ones in queries SQL. - Add
--check-onlycommand line option to just validate configuration. - Drop support for matching query columns positionally, only support name match. This is to avoid confusing behavior with positional match, and make queries more explicit.
- NOTE:
some of the changes above for query definitions are backwards incompatible, thus queries might need updating. Specifically:
- Only named parameters with the
:paramstyle are now supported, queries using positional parameters or other styles of named parameters need to be updated. - Literal
:at the beginning of a word need to be escaped (with backslash) to avoid confusion with parameter markers. Colons that appear inside words don't need to be escaped. - Column names for query results must now always match metric and label names
involved in the query. Position-based match for queries without labels is no
longer supported. Queries can be updated adding
AS <metric_name|label_name>expressions.
- Only named parameters with the
- Convert
Decimalquery results to float (#19).
- Fix failure when multiple query columns have the same name (#18).
- [docker] Add Dockerfile (#17).
- Track doomed queries on a per-database basis (#16).
- Add
--versionoption.
- Support passing sets of parameters for queries.
- Enable autocommit on connection (#10).
- Support custom labels in metrics, setting values from queries result (#7).
- Support matching metrics by query result column name instead of order.
- Disable queries that will certainly always fail (e.g. because of invalid. returned column names/number) (#6).
- Support disconnecting from after each query (#8).
- Rework tests to use actually SQLite in-memory databases instead of fakes.
- Add a
queriesanddatabase_errorsmetrics labeled by database (#1). - Support database DSNs defined as
env:<VARNAME>to supply the dns from the environment (#5).
- Change default port to 9560 (to make it unique).
- Drop support for Python 3.5.
- Add support for
enummetrics. - [snap] Add initial snap support.
- Rework project setup and use pytest.
- Support for python3.7.
- Use asynctest for asynchronous tests.
- Updated toolrack dependency.
- Support aperiodic queries, which are run at every request for the metrics endpoint.
- Fix tests for latest prometheus_aioexporter.
- Documentation cleanups (and conversion to reST).
- Switch to SQLAlchemy. Multiple database engines are now supported.
- Needed database libraries must now be installed separately, as there is no explicit dependency in SQLAlchemy.
- Use connection pools for queries.
- Replace aiopg with asyncpg. The database dsn string is now specified as a
postgres://URI.
- Replace Makefile with tox.
- Fix setup.py issues.
- First release.