Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support queue.failer service to record failed jobs in mongo #739

Closed
wants to merge 4 commits into from
Closed

Support queue.failer service to record failed jobs in mongo #739

wants to merge 4 commits into from

Conversation

ghost
Copy link

@ghost ghost commented Feb 15, 2016

@@ -33,5 +33,16 @@ public function register()
return new MongoConnector($this->app['db']);
});
});

// Support queue failer to record failed jobs
$this->app->singleton('queue.failer', function ($app) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This overwrites a Laravel component and will probably break applications if they are using a different queue backend, right?

If there is no other way to extend, and overwriting is the only way, then this should be in a separate service provider.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

luckily they have an interface there Illuminate\Queue\Failed\FailedJobProviderInterface, so as long as the implemented failer class can handle writing / reading with their expected data format, it will just work, i tested with Amazon SQS on queue:failed, queue:failed-table, queue:flush, queue:forget, queue:retry, queue:work, it works good.
but i do get your concern, will try digging more to see if there's any better way to inject 'queue.failer' more graceful

@jenssegers
Copy link
Contributor

What is actually broken in DatabaseFailedJobProvider? To me it looks like the default Laravel version should work?

@ghost
Copy link
Author

ghost commented Feb 16, 2016

hi @jenssegers , laravel stock DatabaseFailedJobProvider only works with mysql (it populates the failed jobs to mysql failed_jobs table), it's okay if an app has both mysql and mongodb connections, but if laravel app is fully on mongodb (no mysql connection), it will fail when recording the failed jobs

@sbourdette
Copy link

Any merge ?

@Smolevich Smolevich added the Needs investigation Need investigation about bugs described in issue label Jan 20, 2020
@Smolevich
Copy link
Contributor

I think that this issues is not actual

@divine
Copy link
Contributor

divine commented Feb 16, 2020

I think that this issues is not actual

Yeah, not actual, 4 years has passed, closing.

@divine divine closed this Feb 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs investigation Need investigation about bugs described in issue
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants