@POST
 @Produces(MediaType.APPLICATION_XML)
 @Path("/process/instance/{procInstId: [0-9]+}/abort")
 public JaxbGenericResponse abortProcessInstance(@PathParam("procInstId") Long procInstId) {
   Command<?> cmd = new AbortProcessInstanceCommand();
   ((AbortProcessInstanceCommand) cmd).setProcessInstanceId(procInstId);
   internalDoKieSessionOperation(cmd, "Unable to abort process instance " + procInstId);
   return new JaxbGenericResponse(request);
 }
  @POST
  @Path("/process/instance/{procInstId: [0-9]+}/abort")
  public Response process_instance_procInstId_abort(@PathParam("procInstId") Long procInstId) {
    Command<?> cmd = new AbortProcessInstanceCommand();
    ((AbortProcessInstanceCommand) cmd).setProcessInstanceId(procInstId);

    processRequestBean.doKieSessionOperation(
        cmd, deploymentId, procInstId, "Unable to abort process instance " + procInstId);

    return createCorrectVariant(
        new JaxbGenericResponse(uriInfo.getRequestUri().toString()), headers);
  }