private String getInsertIdForRecord ( ELVars elVars , Record record ) throws OnRecordErrorException { String recordId = null ; RecordEL . setRecordInContext ( elVars , record ) ; try { if ( ! ( StringUtils . isEmpty ( conf . rowIdExpression ) ) ) { recordId = rowIdELEval . eval ( elVars , conf . rowIdExpression , String . class ) ; if ( StringUtils . isEmpty ( recordId ) ) { throw new OnRecordErrorException ( record , Errors . BIGQUERY_15 ) ; } } } catch ( ELEvalException e ) { LOG . error ( "Error evaluating Row Expression EL" , e ) ; throw new OnRecordErrorException ( record , Errors . BIGQUERY_10 , e ) ; } return recordId ; }
Evaluate and obtain the row id if the expression is present or return null .