You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description of the problem including expected versus actual behavior:
I used client.Bulk() method to save data to ES, responsed success, except _id had value,other fields had empty value, and no exception for me, any mistake with me?
Steps to reproduce:
my demo code
privatevoidTest(){varindex="test";varkey="Gid";varbulkJobjectList2=newList<JObject>(){new JObject(){{"Gid","1"},{"Title","test index bulk many 1 width JObject"}},new JObject(){{"Gid","2"},{"Title","test index bulk many 2 width JObject"}}};
EsHelper.ClientSet.IndexMany(index, key, bulkJobjectList2);}EsHelperclassIndexManymethod:publicstatic IBulkResponse IndexMany(thisIElasticClientclient,stringindex,stringkeyField,IEnumerable<JObject>res){varresponse= client.Bulk(b => b.Index(index).Type(index).IndexMany(res,(f,o)=> f.Document(o).Id(o[keyField].Value<string>())));returnresponse;}
Expected behavior
data save success,but only _id had vlaue,others were empty.
Provide ConnectionSettings (if relevant):
Provide DebugInformation (if relevant):
`
Valid NEST response built from a successful low level call on POST: /test/test/_bulk?pretty=true&error_trace=true
NEST 6.5.1 is a very old version and out of support..
How did you confirm your data was not written correctly? The bulk response does not return the full documents which means it's totally expected to only see _id and a few other meta fields.
The request looks good, so I assume your data is correctly written. You should try to request it in a second operation or manually check it in Kibana.
NEST/Elasticsearch.Net version 6.5.1:
Elasticsearch version 6.5.4
Description of the problem including expected versus actual behavior:
I used client.Bulk() method to save data to ES, responsed success, except _id had value,other fields had empty value, and no exception for me, any mistake with me?
Steps to reproduce:
my demo code
Expected behavior
data save success,but only _id had vlaue,others were empty.
Provide
ConnectionSettings
(if relevant):Provide
DebugInformation
(if relevant):`
Valid NEST response built from a successful low level call on POST: /test/test/_bulk?pretty=true&error_trace=true
Audit trail of this API call:
Request:
{"index":{"_id":"1"}}
{"Gid":[],"Title":[]}
{"index":{"_id":"2"}}
{"Gid":[],"Title":[]}
Response:
{
"took" : 6,
"errors" : false,
"items" : [
{
"index" : {
"_index" : "test",
"_type" : "test",
"_id" : "1",
"_version" : 3,
"result" : "updated",
"_shards" : {
"total" : 2,
"successful" : 1,
"failed" : 0
},
"_seq_no" : 7,
"_primary_term" : 1,
"status" : 200
}
},
{
"index" : {
"_index" : "test",
"_type" : "test",
"_id" : "2",
"_version" : 3,
"result" : "updated",
"_shards" : {
"total" : 2,
"successful" : 1,
"failed" : 0
},
"_seq_no" : 19,
"_primary_term" : 1,
"status" : 200
}
}
]
}
`
Tasks
The text was updated successfully, but these errors were encountered: