-
-
Save dliappis/f90f30cd605ce9a115799296e044af42 to your computer and use it in GitHub Desktop.
Example rally track to use one type per multiple indices and one index with a custom type field
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"mappings": { | |
"docs": { | |
"properties": { | |
"type": { | |
"type": "keyword" | |
}, | |
"@timestamp": { | |
"format": "epoch_second", | |
"type": "date" | |
}, | |
"clientip": { | |
"type": "ip" | |
}, | |
"request": { | |
"type": "text", | |
"fields": { | |
"raw": { | |
"ignore_above": 256, | |
"type": "keyword" | |
} | |
} | |
}, | |
"status": { | |
"type": "integer" | |
}, | |
"size": { | |
"type": "integer" | |
} | |
} | |
} | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"type": "wclogs1", "@timestamp": 893964617, "clientip":"40.135.0.0", "request": "GET /images/hm_bg.jpg HTTP/1.0", "status": 200, "size": 24736} | |
{"type": "wclogs1", "@timestamp": 893964653, "clientip":"232.0.0.0", "request": "GET /images/hm_bg.jpg HTTP/1.0", "status": 200, "size": 24736} | |
{"type": "wclogs2", "@timestamp": 893964679, "clientip":"247.37.0.0", "request": "GET /french/splash_inet.html HTTP/1.0", "status": 200, "size": 3781} | |
{"type": "wclogs2", "@timestamp": 893964703, "clientip":"247.37.0.0", "request": "GET /french/images/nav_venue_off.gif HTTP/1.0", "status": 304, "size": 0} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"@timestamp": 893964617, "clientip":"40.135.0.0", "request": "GET /images/hm_bg.jpg HTTP/1.0", "status": 200, "size": 24736} | |
{"@timestamp": 893964653, "clientip":"232.0.0.0", "request": "GET /images/hm_bg.jpg HTTP/1.0", "status": 200, "size": 24736} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"@timestamp": 893964679, "clientip":"247.37.0.0", "request": "GET /french/splash_inet.html HTTP/1.0", "status": 200, "size": 3781} | |
{"@timestamp": 893964703, "clientip":"247.37.0.0", "request": "GET /french/images/nav_venue_off.gif HTTP/1.0", "status": 304, "size": 0} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"mappings": { | |
"type": { | |
"properties": { | |
"@timestamp": { | |
"format": "epoch_second", | |
"type": "date" | |
}, | |
"clientip": { | |
"type": "ip" | |
}, | |
"request": { | |
"type": "text", | |
"fields": { | |
"raw": { | |
"ignore_above": 256, | |
"type": "keyword" | |
} | |
} | |
}, | |
"status": { | |
"type": "integer" | |
}, | |
"size": { | |
"type": "integer" | |
} | |
} | |
} | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"description": "multiple indices, one type per index", | |
"indices": [ | |
{ | |
"name": "wclogs1", | |
"auto-managed": false, | |
"body": "mapping-index.json", | |
"types": ["type"] | |
}, | |
{ | |
"name": "wclogs2", | |
"auto-managed": false, | |
"body": "mapping-index.json", | |
"types": ["type"] | |
}, | |
{ | |
"name": "combinedlogs", | |
"auto-managed": false, | |
"body": "custom-type.json", | |
"types": ["docs"] | |
} | |
], | |
"corpora": [ | |
{ | |
"name": "one-type-per-index", | |
"target-type": "type", | |
"documents": [ | |
{ | |
"source-file": "documents-idx1.json", | |
"document-count": 2, | |
"target-index": "wclogs1", | |
"uncompressed-bytes": 251 | |
}, | |
{ | |
"source-file": "documents-idx2.json", | |
"document-count": 2, | |
"target-index": "wclogs2", | |
"uncompressed-bytes": 269 | |
} | |
] | |
}, | |
{ | |
"name": "combineddocbatch", | |
"target-type": "docs", | |
"documents": [ | |
{ | |
"source-file": "documents-combined.json", | |
"document-count": 4, | |
"target-index": "combinedlogs", | |
"uncompressed-bytes": 596 | |
} | |
] | |
} | |
], | |
"challenges": [ | |
{ | |
"name": "one-type-multiple-indices", | |
"description": "Benchmark multiple indices with one type", | |
"default": true, | |
"schedule": [ | |
{ | |
"name": "delete-indices-with-one-type", | |
"index": ["wclogs1", "wclogs2"], | |
"operation": "delete-index" | |
}, | |
{ | |
"name": "create-firstindex", | |
"operation": { | |
"index": "wclogs1", | |
"operation-type": "create-index", | |
"settings": { | |
"index.number_of_replicas": 0 | |
} | |
} | |
}, | |
{ | |
"name": "create-secondindex", | |
"operation": { | |
"index": "wclogs2", | |
"operation-type": "create-index", | |
"settings": { | |
"index.number_of_replicas": 0 | |
} | |
} | |
}, | |
{ | |
"name": "get-health-indices-with-one-type", | |
"operation": { | |
"index": "wclogs*", | |
"operation-type": "cluster-health", | |
"request-params": { | |
"wait_for_status": "yellow" | |
} | |
} | |
}, | |
{ | |
"name": "bulk-indices-with-one-type", | |
"operation": { | |
"operation-type": "bulk", | |
"corpora": ["one-type-per-index"], | |
"bulk-size": 2 | |
}, | |
"warmup-time-period": 5, | |
"clients": 1 | |
} | |
] | |
}, | |
{ | |
"name": "custom-type-in-one-index", | |
"description": "Benchmark custom type field with only one index", | |
"schedule": [ | |
{ | |
"name": "delete-thirdindex", | |
"index": "combinedlogs", | |
"operation": "delete-index" | |
}, | |
{ | |
"name": "create-thirdindex", | |
"operation": { | |
"index": "combinedlogs", | |
"operation-type": "create-index", | |
"settings": { | |
"index.number_of_replicas": 0 | |
} | |
} | |
}, | |
{ | |
"name": "gethealth-thirdindex", | |
"operation": { | |
"index": "combinedlogs", | |
"operation-type": "cluster-health", | |
"request-params": { | |
"wait_for_status": "yellow" | |
} | |
} | |
}, | |
{ | |
"name": "bulkindex-thirdindex", | |
"operation": { | |
"operation-type": "bulk", | |
"corpora": ["combineddocbatch"], | |
"bulk-size": 2 | |
}, | |
"warmup-time-period": 5, | |
"clients": 1 | |
} | |
] | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
There are two challenges here.
Example, to benchmark multiple indices with one type:
Example to benchmark one index with a custom type field: