view mod_statistics_cputotal/mod_statistics_cputotal.lua @ 3363:2681f74750b2

mod_conversejs: Weaken dependency on mod_bosh In trunk after e4c09e335bd9 it will now be possible to set modules_disabled = { "bosh" } to prevent it from being loaded.
author Kim Alvefur <zash@zash.se>
date Fri, 26 Oct 2018 20:07:16 +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
		}
	}
});