Description Usage Arguments Details References Examples
Stores a typed JSON document in an index, making it searchable. When the id param is not set, a unique id will be auto-generated. When you specify an id either a new document will be created, or an existing document will be updated. To enforce "put-if-absent" behavior set the op_type to "create" or use the create() method.
1 2 3 4 5 6 7 8 | index(client, ...)
## S3 method for class 'elasticsearch'
index(client, index, type, id, body,
consistency = NULL, replication = "sync", version = NULL,
version_type = NULL, op_type = NULL, routing = NULL, parent = NULL,
timestamp = NULL, ttl = NULL, refresh = FALSE, timeout = "1m",
raw = FALSE, validate_params = TRUE)
|
index |
String The name of the index |
type |
String The type of the document |
id |
String Document ID |
consistency |
String Explicit write consistency setting for the operation |
replication |
String Specific replication type |
version |
Number Explicit version number for concurrency control |
version_type |
String Specific version type |
routing |
String Specific routing value |
parent |
String ID of the parent document |
timestamp |
String Explicit timestamp for the document |
ttl |
Date Expiration time for the document |
refresh |
Logical Refresh the index after performing the operation |
timeout |
Date Explicit operation timeout |
document |
Json |
index
adds or updates a document in a specific index.
http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/docs-index_.html
1 2 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.