view mod_statistics_cputotal/mod_statistics_cputotal.lua @ 5081:660160fe97fa

mod_password_reset: Add rockspec.build.copy_directories entry to make it work with the plugin installer.
author Benjamin Danowski
date Sat, 29 Oct 2022 12:01:32 +0200
parents 4557ac5c205d
children
line wrap: on
line source

-- Provides total CPU time, useful for DERIVE

module:set_global();

module:provides("statistics", {
	statistics = {
		cpu_total = { -- milliseconds of CPU time used
			get = function()
				return os.clock() * 1000;
			end
		}
	}
});