aurora-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jing Chen (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (AURORA-1737) Descheduling a cron job checks role access before job key existence
Date Wed, 12 Oct 2016 08:02:20 GMT

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

Jing Chen commented on AURORA-1737:
-----------------------------------

Hi Joshua, I create a cron job as following:
{code:title=cron_hello_jing.aurora|borderStyle=solid}
jobs = [
  Job(
    cluster = 'devcluster',
    role = 'www-data',
    environment = 'devel',
    name = 'cron_hello_jing',
    cron_schedule = '*/5 * * * *',
    cron_collision_policy='CANCEL_NEW',
    task = Task(
      name="cron_hello_jing",
      processes=[Process(name="hello_jing",
           cmdline="echo 'hello jing'")],
      resources=Resources(cpu=1, ram=1*MB, disk=8*MB)
    )
  )
]
{code}
However, when I try to deschedule the cron job with a non-existent role
{noformat}
aurora cron deschedule devcluster/abc/devel/cron_hello_jing
{noformat}
It returns as:
{quote}
 INFO] Removing cron schedule for job devcluster/{color:red}abc{color}/devel/cron_hello_world
 INFO] Job abc/devel/cron_hello_world is not scheduled with cron
Cron descheduling succeeded.
{quote}

Can you tell me how to reproduce the bug? 

Thanks
Jing

> Descheduling a cron job checks role access before job key existence
> -------------------------------------------------------------------
>
>                 Key: AURORA-1737
>                 URL: https://issues.apache.org/jira/browse/AURORA-1737
>             Project: Aurora
>          Issue Type: Bug
>          Components: Scheduler
>            Reporter: Joshua Cohen
>            Assignee: Jing Chen
>            Priority: Minor
>
> Trying to deschedule a cron job for a non-existent role returns a permission error rather
than a no-such-job error. This leads to confusion for users in the event of a typo in the
role.
> Given that jobs are world-readable, we should check for a valid job key before applying
permissions.



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

Mime
View raw message