First of all, i've only just recently discovered elasticsearch and am blown away by what it can do. I have only been playing with it for about a week and after setting up kibana and dashboarding my data, i'm wondering why it took me so long to start using it!
I am currently indexing web service calls made by my application. I have configured a SOAPHandler where i can get access to the web service requests and responses and index them in elasticsearch. Up to now, i have indexed the requests and responses as separate documents, but am now trying to relate the response to the corresponding request and am wondering what is the best way to do this in elasticsearch.
Right now my thinking is that for the web service request, i would index a new document and get the id. Then when the web service response is received, i could update the already existing document using the id generated when indexing the request. The document in elasticsearch would contain fields like requestSentTime, responseReceivedTime, requestDocument, responseDocument.
I'm just wondering if the update is more expensive than indexing two separate documents? If so, is it alot more expensive or only a little bit? Can i relate the web service response to the request in a better way for optimal performance?