diff --git a/hysds_commons/__init__.py b/hysds_commons/__init__.py index 595709c..f63aec2 100644 --- a/hysds_commons/__init__.py +++ b/hysds_commons/__init__.py @@ -3,6 +3,6 @@ from __future__ import division from __future__ import absolute_import -__version__ = "1.1.0" +__version__ = "1.1.1" __description__ = "Common HySDS Functions, Utilities, Etc." __url__ = "https://github.jpl.nasa.gov/hysds-org/hysds_commons" diff --git a/hysds_commons/job_iterator.py b/hysds_commons/job_iterator.py index 20981f0..2eb22c2 100644 --- a/hysds_commons/job_iterator.py +++ b/hysds_commons/job_iterator.py @@ -81,11 +81,12 @@ def iterate(component, rule): # Run the query to get the products; for efficiency, run query only if we need the results results = [{"_id": "Transient Faux-Results"}] + sort = ["@timestamp:desc", "id.keyword:asc"] if run_query: if component == "mozart" or component == "figaro": - results = mozart_es.query(index=es_index, body=queryobj) + results = mozart_es.query(index=es_index, body=queryobj, sort=sort) else: - results = grq_es.query(index=es_index, body=queryobj) + results = grq_es.query(index=es_index, body=queryobj, sort=sort) # What to iterate for submission submission_iterable = [{"_id": "Global Single Submission"}] if single else results