Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def putMapping():
- es.indices.put_mapping(
- index=INDEX_NAME,
- doc_type='enron-type',
- body=
- {
- "dynamic": "strict",
- "_source": {"enabled": "false"},
- "properties":
- {
- "content-transfer-encoding": {"type": "string", "store": "false"},
- "message_body": {"type": "string", "analyzer": "english", "store": "false"},
- "content-type": {"type": "string", "store": "false"},
- "x-bcc": {"type": "string", "store": "false"},
- "from": {"type": "string", "store": "false"},
- "x-from": {"type": "string", "store": "false"},
- "x-filename": {"type": "string", "store": "false"},
- "x-folder": {"type": "string", "store": "false"},
- "to": {"type": "string", "store": "true"},
- "x-to": {"type": "string", "store": "false"},
- "mime-version": {"type": "string", "store": "false"},
- "file_name": {"type": "string", "store": "false"},
- "cc": {"type": "string", "store": "false"},
- "x-cc": {"type": "string", "store": "false"},
- "bcc": {"type": "string", "store": "false"},
- "x-bcc": {"type": "string", "store": "false"},
- "subject": {"type": "string", "store": "false"},
- "message-id": {"type": "string", "store": "true"},
- "x-origin": {"type": "string", "store": "false"},
- "sub_holder": {"type": "string", "store": "false"},
- "date": {"type": "date", "format": "EEE, dd MMM yyyy HH:mm:ss Z (z)"},
- "attendees": {"type": "string", "store": "false"},
- "loaded_on": {"type": "date", "store": "false", "format": "dateOptionalTime"},
- "content_size_in_bytes": {"type": "long", "store": "true"}
- }
- }
- )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement