private void updateDocumentOperations() {
        if (documentsToAdd != null) {
            documentOperations.addAll(documentsToAdd);
            documentsToAdd.clear();
        }
    }
Returns true if this variable is present, even if it is null
docproc/src/main/java/com/yahoo/docproc/Processing.java