# Problem with scheduled task in my plugin

**URL:** https://forum.shopware.com/t/problem-with-scheduled-task-in-my-plugin/87934
**Category:** Shopware 6 (English)
**Tags:** general, administration, programming
**Created:** [27. Mai 2021 um 09:57 UTC](https://forum.shopware.com/t/problem-with-scheduled-task-in-my-plugin/87934 "2021-05-27T09:57:26Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![satvikshukla10122000](https://avatars.discourse-cdn.com/v4/letter/s/e495f1/32.png) [@satvikshukla10122000](https://forum.shopware.com/u/satvikshukla10122000)
#### Post date: [27. Mai 2021 um 09:57 UTC](https://forum.shopware.com/t/problem-with-scheduled-task-in-my-plugin/87934/1 "2021-05-27T09:57:26Z")

</div>

hello there, i added a scheduled task and its handler. i also defined them in services.xml file.  
the status of scheduled task is scheduled at first but after the next\_execution\_time is passed the status is changed to queued automatically. Also the code i added in the task handler run() is also not working.  
is ther something i am missing. And i used the bin/console messenger:consume and bin/console scheduled-task:run in command line but did not see my task name there. is there a way to test if my scheduled task is working?

P.S. i have already refered to the documentation of creating a scheduled task but it did not prove to be useful
