AgentProcessStateGate wrapper accepts a resource ID instead of a process ID
use AgentProcessStateGate and remove references to agent_instance_obj.agent_process_id
Merge pull request #1278 from ifreecarve/2013-08-08_process_id_cleanup

Fix references to agent_process_id, fix buildbot