Laravel-SwiftMailer | SwiftMailer integration fix for Queued deamon workers
kandi X-RAY | Laravel-SwiftMailer Summary
kandi X-RAY | Laravel-SwiftMailer Summary
This package works in two possible error-safe modes: sends STOP command after every email is sent, and/or sends RESET/STOP+START commands before every email is sent. As a default, both modes are activated (so called "aggressive" mode). Such approach ensures SMTP connection is closed to avoid timeouts and broken pipes, or maintains it active for whole application living cycle. This is extremely important for long-living applications. E.g. when emails are sent through Beanstalkd + Supervisor + Laravel Queue Daemon Worker architecture, Laravel application never quits - therefore SMTP connection is kept active and timeouts after some time. Stopping, resetting and/or restarting SMTP connection automaticaly solves this problem in general. N.B. While auto-reset feature is great, sometimes it's not a preferred behaviour. Be sure to check your SMTP server configuration before using this package.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Stop Swift Transport
- Reset Swift Transport .
- Register the mailer .
- Get Swift Mailer Transport
- Get the transport transport object .
- Boot the package .
- Get the service provider .
- Get the facade accessor .
Laravel-SwiftMailer Key Features
Laravel-SwiftMailer Examples and Code Snippets
// disable auto reset
Mailer::disableAutoReset();
// enable it back
Mailer::enableAutoReset();
// Set my status
Mailer::setAutoReset(true);
// check if auto-reset is enabled
if ( Mailer::autoResetEnabled() ) { ...
// send only STOP after every email
"require": {
"yozaz/laravel-swiftmailer": "~4.0"
}
composer update
'YOzaz\LaravelSwiftmailer\ServiceProvider',
'Mail' => 'YOzaz\LaravelSwiftmailer\Facade',
var $mailer = App::make('laravel-swiftmailer.mailer');
var $mailer = new \YOzaz\LaravelSwiftmailer\Mailer();
var $my_custom_mailer = App::make('mailer');
// pass custom mailer and disable auto-reset
var $mailer = new \YOzaz\LaravelSwiftmailer\Maile
Community Discussions
Trending Discussions on Laravel-SwiftMailer
QUESTION
I know it is a duplicate issue in StackOverFlow (Laravel SwiftMailer : Expected response code 250 but got code "530", with message "530-5.5.1 Authentication Required) however, I'm done all the remedies discussed there but still no luck. I'm using mailtrap.io using my GMail account. Here is the .env file and mail.php (under config):
.env ...ANSWER
Answered 2018-May-30 at 08:14I' may suggest you use this as well, it worked for me,
Please Note if you're using Gmail: create a gmail app password, but be sure to your 2 Step verification set up, from sign in and securiity, the following link: https://myaccount.google.com/apppasswords to setup app password, use that and follow procedure 2 after this return to set up gmail with smtp.
please note: code down below are for mail.php file
(do not forget to use: php artisan config:cache) after changes to .env file as well
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install Laravel-SwiftMailer
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page