diff --git a/.travis.yml b/.travis.yml index 569bf12d6..745761bc1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,4 +1,7 @@ language: python +arch: + - amd64 + - ppc64le python: - '3.6' env: @@ -29,7 +32,28 @@ jobs: - env: TOXENV=py36 ES_VERSION=6.2.4 - env: TOXENV=py36 ES_VERSION=6.0.1 - env: TOXENV=py36 ES_VERSION=5.6.16 - + # adding code to run on powersystems + - stage: 'Elasticsearch test' + env: TOXENV=py36 ES_VERSION=7.0.0-linux-x86_64 + arch: ppc64le + - env: TOXENV=py36 ES_VERSION=6.6.2 + arch: ppc64le + - env: TOXENV=py36 ES_VERSION=6.3.2 + arch: ppc64le + - env: TOXENV=py36 ES_VERSION=6.2.4 + arch: ppc64le + - env: TOXENV=py36 ES_VERSION=6.0.1 + arch: ppc64le + - env: TOXENV=py36 ES_VERSION=5.6.16 + arch: ppc64le +jobs: + exclude: + - env: TOXENV=py36 ES_VERSION=7.0.0-linux-x86_64 + arch: ppc64le + - env: TOXENV=py36 ES_VERSION=6.6.2 + arch: ppc64le + - env: TOXENV=py36 ES_VERSION=6.3.2 + arch: ppc64le deploy: provider: pypi user: yelplabs diff --git a/docs/source/ruletypes.rst b/docs/source/ruletypes.rst index a947a77b7..ff3763712 100644 --- a/docs/source/ruletypes.rst +++ b/docs/source/ruletypes.rst @@ -1931,7 +1931,7 @@ Developers in India can use Exotel alerter, it will trigger an incident to a mob The alerter requires the following option: -``exotel_accout_sid``: This is sid of your Exotel account. +``exotel_account_sid``: This is sid of your Exotel account. ``exotel_auth_token``: Auth token assosiated with your Exotel account. diff --git a/elastalert/elastalert.py b/elastalert/elastalert.py index 24b10ced9..b078c86db 100755 --- a/elastalert/elastalert.py +++ b/elastalert/elastalert.py @@ -652,7 +652,8 @@ def run_query(self, rule, start=None, end=None, scroll=False): try: if rule.get('scroll_id') and self.thread_data.num_hits < self.thread_data.total_hits and should_scrolling_continue(rule): - self.run_query(rule, start, end, scroll=True) + if not self.run_query(rule, start, end, scroll=True): + return False except RuntimeError: # It's possible to scroll far enough to hit max recursive depth pass @@ -894,7 +895,8 @@ def run_rule(self, rule, endtime, starttime=None): if rule.get('aggregation_query_element'): if endtime - tmp_endtime == segment_size: - self.run_query(rule, tmp_endtime, endtime) + if not self.run_query(rule, tmp_endtime, endtime): + return 0 self.thread_data.cumulative_hits += self.thread_data.num_hits elif total_seconds(rule['original_starttime'] - tmp_endtime) == 0: rule['starttime'] = rule['original_starttime'] diff --git a/elastalert/schema.yaml b/elastalert/schema.yaml index cc5d52395..1241315dc 100644 --- a/elastalert/schema.yaml +++ b/elastalert/schema.yaml @@ -286,9 +286,9 @@ properties: slack_text_string: {type: string} slack_ignore_ssl_errors: {type: boolean} slack_ca_certs: {type: string} - slack_attach_kibana_discover_url {type: boolean} - slack_kibana_discover_color {type: string} - slack_kibana_discover_title {type: string} + slack_attach_kibana_discover_url: {type: boolean} + slack_kibana_discover_color: {type: string} + slack_kibana_discover_title: {type: string} ### Mattermost mattermost_webhook_url: *arrayOfString diff --git a/requirements.txt b/requirements.txt index c66ca8d79..9c32052d0 100644 --- a/requirements.txt +++ b/requirements.txt @@ -15,7 +15,6 @@ prison>=0.1.2 py-zabbix==1.1.3 PyStaticConfiguration>=0.10.3 python-dateutil>=2.6.0,<2.7.0 -python-magic>=0.4.15 PyYAML>=5.1 requests>=2.0.0 stomp.py>=4.1.17 diff --git a/setup.py b/setup.py index 30ef9495f..2845836a7 100644 --- a/setup.py +++ b/setup.py @@ -47,7 +47,6 @@ 'stomp.py>=4.1.17', 'texttable>=0.8.8', 'twilio>=6.0.0,<6.1', - 'python-magic>=0.4.15', 'cffi>=1.11.5' ] )