Elasticsearch Bulk Update with doc does not work

I am trying to update the fields in elastic, with the elastic query using bulk api

This is how I build the query for doc update:

public static String getBulkQueryWithDoc(RecordsBasedOnId recordsBasedOnId){
        String update = String.format("{ \"update\" : { \"_id\" : \"%s\"} }",recordsBasedOnId.getId());
        String idDoc = String.format("{ \"doc\" : { \"id\" : \"%s\"} }",recordsBasedOnId.getId());
        String idLongDesc = String.format("{ \"doc\" : { \"long_desc\" : \"%s\"}, \"_source\": true }",recordsBasedOnId.getLongDescription());
        String scope = String.format("{ \"doc\" : { \"scope\" : \"%s\"}, \"_source\": true }",recordsBasedOnId.getScope());
        String projectCountry = String.format("{ \"doc\" : { \"%s\" : \"%s\"}, \"doc_as_upsert\": true }","TEST100@USA",recordsBasedOnId.getLongDescription());
        StringJoiner bulkRequestBody = new StringJoiner("");
        bulkRequestBody.add(update);
        bulkRequestBody.add("\n");
        bulkRequestBody.add(idDoc);
        bulkRequestBody.add("\n");
        bulkRequestBody.add(scope);
        bulkRequestBody.add("\n");
        bulkRequestBody.add(idLongDesc);
        bulkRequestBody.add("\n");
        bulkRequestBody.add(projectCountry);
        bulkRequestBody.add("\n");
        return getBulkQueryWithScript(recordsBasedOnId);
        //return bulkRequestBody.toString();
    }

So when I run the query

String myQuery = getBulkQueryWithDoc(eachRec);
HttpEntity entity = new NStringEntity(myQuery.toString(),ContentType.APPLICATION_JSON);
                        try {
                            Response response = clientRest.performRequest("POST","/_index/_type/_bulk?refresh=true",Collections.emptyMap(),entity);
                            System.out.println(EntityUtils.toString(response.getEntity()));
                            System.out.println(response.getStatusLine().getStatusCode()==HttpStatus.SC_OK);
                        }
                        catch (Exception e) {
                            logger.error("There was no data to bulk update the existing records in the Elastic DB !!!");
                            e.printStackTrace();
                        }

I get the response as

{"took":62,"errors":false,"items":[{"update":{"_index":"_index","_type":"_type","_id":"my_id","_version":15,"status":200}}]}

It says the update is done without any error. But when I checked by calling elastic search url the data did not update

But if I do update the fields using the Script, the data is getting added.

public static String getBulkQueryWithScript(RecordsBasedOnId recordsBasedOnId){
        String update = String.format("{ \"update\" : { \"_id\" : \"%s\"} }",recordsBasedOnId.getId());
        String scopeScript = String.format("{ \"script\" : \"ctx._source.scope=scope;\",\"params\" : { \"scope\" : \"%s\"}}",recordsBasedOnId.getScope());
        String longDescScript = String.format("{ \"script\" : \"ctx._source.long_desc=long_desc;\",\"params\" : { \"long_desc\" : \"%s\"}}",recordsBasedOnId.getLongDescription());
        String projectCountry = String.format("{ \"script\" : { \"%s\" : \"%s\"}, \"doc_as_upsert\": true }","TEST100@USA",recordsBasedOnId.getLongDescription());
        StringJoiner bulkRequestBody = new StringJoiner("");
        bulkRequestBody.add(update);
        bulkRequestBody.add("\n");
        bulkRequestBody.add(scopeScript);
        bulkRequestBody.add("\n");
        bulkRequestBody.add(longDescScript);
        bulkRequestBody.add("\n");
        bulkRequestBody.add(projectCountry);
        bulkRequestBody.add("\n");
        return bulkRequestBody.toString();
    }

Why the update did not happen with doc? How to resolve this?