web_services: implement os timestamp query.
The os user and sys elapsed times are very useful for performance metrics, they can tell us how much did the openerp server try for some operation. Conflicts: bin/service/web_services.py bzr revid: p_christ@hol.gr-20101116162025-go5lx4qs658pt7t5
This commit is contained in:
@@ -385,7 +385,7 @@ class common(_ObjectService):
|
||||
'login_message','get_stats', 'check_connectivity',
|
||||
'list_http_services']:
|
||||
pass
|
||||
elif method in ['get_available_updates', 'get_migration_scripts', 'set_loglevel']:
|
||||
elif method in ['get_available_updates', 'get_migration_scripts', 'set_loglevel', 'get_os_time']:
|
||||
passwd = params[0]
|
||||
params = params[1:]
|
||||
security.check_super(passwd)
|
||||
@@ -567,6 +567,9 @@ GNU Public Licence.
|
||||
|
||||
def exp_check_connectivity(self):
|
||||
return bool(sql_db.db_connect('template1'))
|
||||
|
||||
def exp_get_os_time(self):
|
||||
return os.times()
|
||||
|
||||
common()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user