1 new commit in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/commits/3d92d6f0ec74/ Changeset: 3d92d6f0ec74 User: natefoo Date: 2014-09-16 23:51:40 Summary: Stop recovering jobs that don't need to be recovered - jobs in the 'NEW' state when tracking in the database. Affected #: 1 file diff -r 77ec2da4bab3d7649aaff20edc8a8a1aa6594bdd -r 3d92d6f0ec740391c9b69c0faef1b4cd0c66e946 lib/galaxy/jobs/handler.py --- a/lib/galaxy/jobs/handler.py +++ b/lib/galaxy/jobs/handler.py @@ -101,19 +101,22 @@ In case the activation is enforced it will filter out the jobs of inactive users. """ jobs_at_startup = [] + if self.track_jobs_in_database: + in_list = ( model.Job.states.QUEUED, + model.Job.states.RUNNING ) + else: + in_list = ( model.Job.states.NEW, + model.Job.states.QUEUED, + model.Job.states.RUNNING ) if self.app.config.user_activation_on: jobs_at_startup = self.sa_session.query( model.Job ).enable_eagerloads( False ) \ .outerjoin( model.User ) \ - .filter( ( ( model.Job.state == model.Job.states.NEW ) \ - | ( model.Job.state == model.Job.states.RUNNING ) \ - | ( model.Job.state == model.Job.states.QUEUED ) ) \ + .filter( model.Job.state.in_( in_list ) \ & ( model.Job.handler == self.app.config.server_name ) \ & or_( ( model.Job.user_id == None ), ( model.User.active == True ) ) ).all() else: jobs_at_startup = self.sa_session.query( model.Job ).enable_eagerloads( False ) \ - .filter( ( ( model.Job.state == model.Job.states.NEW ) \ - | ( model.Job.state == model.Job.states.RUNNING ) \ - | ( model.Job.state == model.Job.states.QUEUED ) ) \ + .filter( model.Job.state.in_( in_list ) \ & ( model.Job.handler == self.app.config.server_name ) ).all() for job in jobs_at_startup: Repository URL: https://bitbucket.org/galaxy/galaxy-central/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.