Environment env = ((EnvironmentFactory)processEngine).openEnvironment();
try
{
ExecutionService execService = this.processEngine.getExecutionService();
ProcessInstanceQuery query = execService.createProcessInstanceQuery();
query.processInstanceId(instanceId);
ExecutionImpl processInstance = (ExecutionImpl) query.uniqueResult();
String currentActivity = processInstance.getProcessInstance().getActivityName();
// get coordinates
RepositoryService repoService = this.processEngine.getRepositoryService();