You can get the taskinstance which is currently executed from a Jbpmcontext and from which you can get the processInstance of that task.
Ok. Thanks. But I need in particular to disable a ProcessDefinition from a taskMgmtDefinition(). Is it possible?
Why You need to disable a processDefinition. ProcessDefinition is something you have deployed .Its something like making it available to be used for your process. So i conclude it is not yet made active .