diff --git a/.github/workflows/packaging.yml b/.github/workflows/packaging.yml index 3119bc17..e24b9efe 100644 --- a/.github/workflows/packaging.yml +++ b/.github/workflows/packaging.yml @@ -21,9 +21,7 @@ jobs: with: module-name: 'metrics' version-pre-extraction-hook: | - local rock_utils = require('test.rock_utils') - rock_utils.remove_builtin('metrics') - rock_utils.assert_nonbuiltin('metrics') + require('test.rock_utils').assert_nonbuiltin('metrics') package: # Skip pull request jobs when the source branch is in the same diff --git a/.github/workflows/push_rockspec.yml b/.github/workflows/push_rockspec.yml index 462474df..e0d62c63 100644 --- a/.github/workflows/push_rockspec.yml +++ b/.github/workflows/push_rockspec.yml @@ -24,9 +24,7 @@ jobs: with: module-name: 'metrics' version-pre-extraction-hook: | - local rock_utils = require('test.rock_utils') - rock_utils.remove_builtin('metrics') - rock_utils.assert_nonbuiltin('metrics') + require('test.rock_utils').assert_nonbuiltin('metrics') push-scm-rockspec: runs-on: [ ubuntu-20.04 ] diff --git a/.gitignore b/.gitignore index 1590b603..21c7b86c 100644 --- a/.gitignore +++ b/.gitignore @@ -17,3 +17,4 @@ doc/locale/en/ *.lua.c build.luarocks +packpack diff --git a/CHANGELOG.md b/CHANGELOG.md index c4c7705c..ba791d24 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -23,6 +23,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - simultaneous `include` and `exclude` arguments (`exclude` has higher priority) - Build rock with cmake +- Override built-in metrics, if installed ### Deprecated - Passing nonexistent metrics to `enable_default_metrics()` diff --git a/CMakeLists.txt b/CMakeLists.txt index c370eece..afeeb770 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -18,3 +18,8 @@ install( DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/cartridge DESTINATION ${TARANTOOL_INSTALL_LUADIR} ) + +install( + DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/${PROJECT_NAME} + DESTINATION ${TARANTOOL_INSTALL_LUADIR}/override +) diff --git a/rpm/tarantool-metrics.spec b/rpm/tarantool-metrics.spec index dcbbdea4..cdf8a762 100644 --- a/rpm/tarantool-metrics.spec +++ b/rpm/tarantool-metrics.spec @@ -23,10 +23,13 @@ Easy collecting, storing and manipulating metrics timeseriess. mkdir -p %{br_luapkgdir} cp -rv metrics %{br_luapkgdir} cp -rv cartridge %{br_luapkgdir} +mkdir %{br_luapkgdir}/override +cp -rv metrics %{br_luapkgdir}/override %files %{luapkgdir}/metrics %{luapkgdir}/cartridge + %{luapkgdir}/override %doc README.md %doc doc/monitoring/getting_started.rst