visualize-api needs to load the 10 latest jobs, however it needs to apply a filter.
Allow this by adding a param (?types=
Current code:
# all the jobs that are not repair or failed or pending, sorted by createdAt, descending, limit 10
jobs = collection.find({"$nor": [{"type": {"$regex": "repair"}}, {"status": {"$regex": "failed"}}, {"status": {"$regex": "terminated"}}, {"status": {"$regex": "pending"}}]}).sort(
"createdAt", -1).limit(10)
visualize-api needs to load the 10 latest jobs, however it needs to apply a filter.
Allow this by adding a param (?types=
Current code: