From 04e652e605ca52ab36cffd5e70615289dc1411d0 2016-08-08 16:12:03 From: cmoyer Date: 2016-08-08 16:12:03 Subject: [PATCH] Convert "message" searches to boolean "and" instead of "or" queries. --- diff --git a/backend/src/appenlight/models/services/log.py b/backend/src/appenlight/models/services/log.py index cca2e00..548dd1a 100644 --- a/backend/src/appenlight/models/services/log.py +++ b/backend/src/appenlight/models/services/log.py @@ -103,7 +103,13 @@ class LogService(BaseService): messages = filter_settings.get('message') if messages: query['query']['filtered']['query'] = { - 'match': {"message": ' '.join(messages)}} + 'match': { + 'message': { + 'query': ' '.join(messages), + 'operator': 'and' + } + } + } return query @classmethod