You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tapestry.apache.org by "Bob Harner (JIRA)" <ji...@apache.org> on 2016/09/11 13:54:20 UTC

[jira] [Comment Edited] (TAP5-2562) remove periodic job from PeriodicExecutor by name

    [ https://issues.apache.org/jira/browse/TAP5-2562?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15481662#comment-15481662 ] 

Bob Harner edited comment on TAP5-2562 at 9/11/16 1:54 PM:
-----------------------------------------------------------

There is already the ability to remove a job (via PeriodicJob.cancel(), but the part missing is the ability to return a list of jobs by name.

{code}
public List<PeriodicJob> getJobs(String name);
{code}

Then removing a job by name would be trivial:

{code}
for (PeriodicJob job : periodicExecutor.getJobs(name) {
    job.cancel();
}
{code}

At the same time, getting a list of all jobs regardless of name would be as useful:

{code}
public List<PeriodicJob> getJobs();
{code}

For Tapestry 5.5 (which will require Java 8) the implementations could be added as default methods to the PeriodicExecutor interface to avoid breaking the API's backward compatibility, although I suspect few if any apps have custom implementations so maybe that's not so important.


was (Author: bobharner):
There is already the ability to remove a job (via PeriodicJob.cancel(), but the part missing is the ability to return a list of jobs by name.

{code}
public List<PeriodicJob> getJobs();
{code}

and

{code}
public List<PeriodicJob> getJobs(String name);
{code}

For Tapestry 5.5 (which will require Java 8) the implementations could be added as default methods to the PeriodicExecutor interface to avoid breaking the API's backward compatibility, although I suspect few if any apps have custom implementations so maybe that's not so important.

> remove periodic job from PeriodicExecutor by name
> -------------------------------------------------
>
>                 Key: TAP5-2562
>                 URL: https://issues.apache.org/jira/browse/TAP5-2562
>             Project: Tapestry 5
>          Issue Type: Wish
>          Components: tapestry-ioc
>    Affects Versions: 5.4.1
>            Reporter: Sven Homburg
>            Priority: Minor
>
> it would nice to let us remove a periodic job from executor by the name of the job.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)