You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Mircea Stan (Jira)" <ji...@apache.org> on 2025/04/04 08:56:00 UTC

[jira] [Created] (SLING-12737) The method findJobs in JobManagerImpl does not accept a template containing an operation

Mircea Stan created SLING-12737:
-----------------------------------

             Summary: The method findJobs in JobManagerImpl does not accept a template containing an operation
                 Key: SLING-12737
                 URL: https://issues.apache.org/jira/browse/SLING-12737
             Project: Sling
          Issue Type: Bug
          Components: Event
    Affects Versions: Event 4.3.14
            Reporter: Mircea Stan


I am using the method findJobs in JobManager to iterate through all Sling jobs.

I would like to find all history jobs with a finished date before a certain date specified by a user.

First of all, there are no tests that test templates with operators, so I had to reverse engineer how should I build the template.

In the end, I created a template like this:
{code:java}
Map<String, Object> templateBefore = Map.of("<" + JobImpl.PROPERTY_FINISHED_DATE,"2026-04-03T11:38:25.360+03:00");  {code}
The template is not working though because the key is encoded before extracting the first character and the first character is no longer '<'.

Could you confirm the bug and if it is not a bug, share a template that can work in the scenario I described?

Thanks!



--
This message was sent by Atlassian Jira
(v8.20.10#820010)