Skip to content
This repository was archived by the owner on Mar 4, 2024. It is now read-only.

Commit 5ca8555

Browse files
authored
Merge pull request #5 from apploitech/050319MR_add_latest_jobs_query
Add get latest jobs query
2 parents 5d1bffc + 6c85adf commit 5ca8555

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

mrq/job.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -654,6 +654,11 @@ def trace_memory_stop(self):
654654
w=1
655655
)
656656

657+
def get_latest_jobs_with_query(query):
658+
jobs = context.connections.mongodb_jobs.mrq_jobs
659+
tasks = jobs.find(query, sort=[('datequeued', DESCENDING)])
660+
return tasks
661+
657662
def get_latest_job_with_query(query):
658663
jobs = context.connections.mongodb_jobs.mrq_jobs
659664
task = jobs.find_one(query, sort=[('datequeued', DESCENDING)])

mrq/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
VERSION = "0.9.20"
1+
VERSION = "0.9.21"
22

33
if __name__ == "__main__":
44
import sys

0 commit comments

Comments
 (0)