public void recordBlockVolumeOperation(DbClient dbClient,OperationTypeEnum opType,Operation.Status status,Object... extParam){
  try {
    boolean opStatus=(Operation.Status.ready == status) ? true : false;
    String evType;
    evType=opType.getEvType(opStatus);
    String evDesc=opType.getDescription();
    String opStage=AuditLogManager.AUDITOP_END;
    _logger.info("opType: {} detail: {}",opType.toString(),evType.toString() + ':' + evDesc);
    recordBourneVolumeEvent(dbClient,getId(),evType,status,evDesc);
    String id=(String)extParam[0];
switch (opType) {
case CREATE_BLOCK_VOLUME:
case DELETE_BLOCK_VOLUME:
      AuditBlockUtil.auditBlock(dbClient,opType,opStatus,opStage,id);
    break;
case EXPAND_BLOCK_VOLUME:
  String size=(String)extParam[1];
AuditBlockUtil.auditBlock(dbClient,opType,opStatus,opStage,id,size);
break;
case CREATE_VOLUME_FULL_COPY:
AuditBlockUtil.auditBlock(dbClient,opType,opStatus,opStage,id);
break;
case DETACH_VOLUME_FULL_COPY:
AuditBlockUtil.auditBlock(dbClient,opType,opStatus,opStage,id);
break;
case RESTORE_VOLUME_FULL_COPY:
case RESYNCHRONIZE_VOLUME_FULL_COPY:
case ACTIVATE_VOLUME_FULL_COPY:
AuditBlockUtil.auditBlock(dbClient,opType,opStatus,opStage,id);
break;
default :
_logger.error("unrecognized block volume operation type");
}
}
 catch (Exception e) {
_logger.error("Failed to record block volume operation {}, err: {}",opType.toString(),e);
}
}

public void recordBlockVolumeOperation ( DbClient dbClient , OperationTypeEnum opType , Operation . Status status , Object ... extParam ) { try { boolean opStatus = ( Operation . Status . ready == status ) ? true : false ; String evType ; evType = opType . getEvType ( opStatus ) ; String evDesc = opType . getDescription ( ) ; String opStage = AuditLogManager . AUDITOP_END ; _logger . info ( "opType: {} detail: {}" , opType . toString ( ) , evType . toString ( ) + ':' + evDesc ) ; recordBourneVolumeEvent ( dbClient , getId ( ) , evType , status , evDesc ) ; String id = ( String ) extParam [ 0 ] ; switch ( opType ) { case CREATE_BLOCK_VOLUME : case DELETE_BLOCK_VOLUME : AuditBlockUtil . auditBlock ( dbClient , opType , opStatus , opStage , id ) ; break ; case EXPAND_BLOCK_VOLUME : String size = ( String ) extParam [ 1 ] ; AuditBlockUtil . auditBlock ( dbClient , opType , opStatus , opStage , id , size ) ; break ; case CREATE_VOLUME_FULL_COPY : AuditBlockUtil . auditBlock ( dbClient , opType , opStatus , opStage , id ) ; break ; case DETACH_VOLUME_FULL_COPY : AuditBlockUtil . auditBlock ( dbClient , opType , opStatus , opStage , id ) ; break ; case RESTORE_VOLUME_FULL_COPY : case RESYNCHRONIZE_VOLUME_FULL_COPY : case ACTIVATE_VOLUME_FULL_COPY : AuditBlockUtil . auditBlock ( dbClient , opType , opStatus , opStage , id ) ; break ; default : _logger . error ( "unrecognized block volume operation type" ) ; } } catch ( Exception e ) { _logger . error ( "Failed to record block volume operation {}, err: {}" , opType . toString ( ) , e ) ; } }
record block volume related event and audit
