add support for dynamic loading agent modules (suggested by Nigel Roberts),