add a management command, start to work out better jid handling