# Succeeded jobs deleted

**URL:** <https://discuss.hangfire.io/t/succeeded-jobs-deleted/341>\
**Category:** question\
**Tags:** sql-server\
**Created:** [October 30, 2014, 9:40am UTC](https://discuss.hangfire.io/t/succeeded-jobs-deleted/341 "2014-10-30T09:40:35Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![gtarbell](https://dub1.discourse-cdn.com/flex017/user_avatar/discuss.hangfire.io/gtarbell/32/63_2.png) [@gtarbell](https://discuss.hangfire.io/u/gtarbell)\
**Post date:** [November 6, 2014, 4:12pm UTC](https://discuss.hangfire.io/t/succeeded-jobs-deleted/341/2 "2014-11-06T16:12:17Z")

</div>

This is expected functionality, and only occurs for completed or deleted jobs, any pending or failed jobs are not removed. If you want more information, you can see the source code here:

[https://github.com/HangfireIO/Hangfire/search?utf8=✓&q=JobExpirationTimeout&type=Code](https://github.com/HangfireIO/Hangfire/search?utf8=%E2%9C%93&q=JobExpirationTimeout&type=Code)

or a conversation with the creator of hangfire on how to adjust the length of the expiration here:

> [@How to configure the retention time of job?](http://discuss.hangfire.io/t/how-to-configure-the-retention-time-of-job/34/2):
>
> First of all, retention, or expiration time is setting up only for successful and deleted jobs. Other job states, including the failed state, don’t have any expiration time. That is why your failed jobs will be kept infinitely before you fix/retry or delete them manually. But if you really want to set up retention time for succeeded or deleted jobs, you can add the following job filter (they are like action filters in [ASP.NET](http://ASP.NET) MVC): public class ProlongExpirationTimeAttribute : JobFilterAttribu…

later,  
Geddy

---

_[View the full topic](https://discuss.hangfire.io/t/succeeded-jobs-deleted/341)._
