Contexts available to commands executed by CommandJob don't have access to the 
repository
-----------------------------------------------------------------------------------------

                 Key: MGNLSCH-35
                 URL: http://jira.magnolia-cms.com/browse/MGNLSCH-35
             Project: Magnolia Scheduler Module
          Issue Type: Bug
    Affects Versions: 1.5.4
            Reporter: Grégory Joseph
            Assignee: Philipp Bärfuss
            Priority: Critical
             Fix For: 1.5.5


When a command is executed via the scheduler, i.e by 
{{info.magnolia.module.scheduler.CommandJob}}, its context (passed to 
{{execute()}} or as {{MgnlContext.getInstance()}} don't have their 
{{repositoryStrategy}} set, resulting in an ugly {{NullPointerException}}.

At the very least, this should not throw an NPE, but a more explicit exception. 
But I don't see there's a reason for this ? We can't have a user-specific 
context, but then why not pass the system context, rather than let developers 
believe they can use the given context, when really they can't ?
(alternatively, if we had a "sudo" type of API, we could go as far as letting 
the scheduled job use the context of a specific configured user)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.magnolia-cms.com/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       


----------------------------------------------------------------
For list details, see: http://www.magnolia-cms.com/community/mailing-lists.html
Alternatively, use our forums: http://forum.magnolia-cms.com/
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------

Reply via email to