message clean up, add agentStartGracePeriod global parameter

Signed-off-by: nigel <nigel.cook@hp.com>