couchbase-protolib/src/main/java/com/streamsets/pipeline/stage/processor/couchbase/CouchbaseProcessor.java
private Observable<Record> setDocumentInRecord(Record record, JsonDocument doc) {
    if(doc.content() == null) {
      LOG.debug("Document does not exist: {}", doc.id());
      return handleError(record, Errors.COUCHBASE_26, true);
    }

    try {
      record.set(config.outputField, jsonToField(doc.content().toMap()));
      record.getHeader().setAttribute(config.CAS_HEADER_ATTRIBUTE, String.valueOf(doc.cas()));
      return Observable.just(record);
    } catch (IOException e) {
      LOG.debug("Unable to set KV lookup in record for: {}", doc.id());
      return handleError(record, Errors.COUCHBASE_19, e, false);
    }
  }
private Observable<Record> setDocumentInRecord(Record record, JsonDocument doc) {
    if(doc.content() == null) {
      LOG.debug("Document does not exist: {}", doc.id());
      return handleError(record, Errors.COUCHBASE_26, true);
    }

    try {
      record.set(config.outputField, jsonToField(doc.content().toMap()));
      record.getHeader().setAttribute(config.CAS_HEADER_ATTRIBUTE, String.valueOf(doc.cas()));
      return Observable.just(record);
    } catch (IOException e) {
      LOG.debug("Unable to set KV lookup in record for: {}", doc.id());
      return handleError(record, Errors.COUCHBASE_19, e, false);
    }
  }
private Observable < Record > setDocumentInRecord ( Record record , JsonDocument doc ) { if ( doc . content ( ) == null ) { LOG . debug ( "Document does not exist: {}" , doc . id ( ) ) ; return handleError ( record , Errors . COUCHBASE_26 , true ) ; } try { record . set ( config . outputField , jsonToField ( doc . content ( ) . toMap ( ) ) ) ; record . getHeader ( ) . setAttribute ( config . CAS_HEADER_ATTRIBUTE , String . valueOf ( doc . cas ( ) ) ) ; return Observable . just ( record ) ; } catch ( IOException e ) { LOG . debug ( "Unable to set KV lookup in record for: {}" , doc . id ( ) ) ; return handleError ( record , Errors . COUCHBASE_19 , e , false ) ; } }
Writes full document lookup values to the record

@param record the record being processed
@param doc the JsonDocument from Couchbase
@return an Observable of the updated record
Writes full document lookup values to the record