Merge pull request #178 from flip111/patch-1

update docs about DocId
This commit is contained in:
Chris Allen 2017-12-05 13:02:33 -06:00 committed by GitHub
commit 1e14794f5c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -809,7 +809,10 @@ versionCtlParams cfg =
-- | 'indexDocument' is the primary way to save a single document in
-- Elasticsearch. The document itself is simply something we can
-- convert into a JSON 'Value'. The 'DocId' will function as the
-- primary key for the document.
-- primary key for the document. You are encouraged to generate
-- your own id's and not rely on ElasticSearch's automatic id
-- generation. Read more about it here:
-- https://github.com/bitemyapp/bloodhound/issues/107
--
-- >>> resp <- runBH' $ indexDocument testIndex testMapping defaultIndexDocumentSettings exampleTweet (DocId "1")
-- >>> print resp