Description
I've noticed that during indexing documents current implementation always omits "id" inside the document source, see code example https://github.com/topcoder-platform/taas-es-processor/blob/dev/src/services/JobProcessorService.js#L54
await esClient.createExtra({
index: config.get('esConfig.ES_INDEX_JOB'),
id: job.id,
transactionId,
body: _.omit(job, 'id'), // <---------------- omit "id" here
refresh: constants.esRefreshOption
})
I haven't seen such an approach in other Topcoder ES Processsors and I don't know about any benefit of such approach.
@imcaizheng as I understand you implemented the initial code for this processor in the challenge https://www.topcoder.com/challenges/a7bc3928-5260-436e-af87-53adfa4c248f.
Could you please let me know, if this was done on propose, or we can update the code of the processor to keep the "id" inside the body?
There is no particular need to have "id" either, though it feels a bit inconsistent, as we define "id" in mapping but we don't populate it, so it is empty if we look at the data in ES: