-
-
Notifications
You must be signed in to change notification settings - Fork 166
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
Curl error on Laravel 11 #219
Comments
If something works locally but not on a remote machine, it's usually something in the remote environment that doesn't work. I'm not familiar with this particular error, but it looks like a networking problem, perhaps there's a misbehaving proxy somewhere or another problem with the internet/network connection. I can not do more than take guesses, but I'm quite sure this is not something I can fix in code, so I'll have to close this issue. Please keep in mind that I don't work for Google, so I can't say anything about Firebase, the service. If you believe your environment has no problems, you might want to create a support issue with them. Good luck! |
Sorry but everything is correct on my side let me clear. those 2 projects are on both laravel 11 but one is old release and one is new. the new one does not work. as soon as I upgraded the old to new its stopped working. you can try yourself installing the latest laravel. |
So now i figured out the issue |
Thank you for providing this detail! 7.10 switched from using consequent HTTP/1.1 request to concurrent HTTP/2 requests. This by itself shouldn't be a problem, but the memory usage can increase, depending on how many requests are sent, due to changes on how these requests are handled by the SDK. How many messages are you sending? It should be possible to reduce the memory footprint by sending the messages in batches instead of all at once. |
Yeah I found the issue that when use old version of nginx it doesn't support http2 and it doesn't send proper request body to Google api so when update the nginx version everything solved. |
Thank you for sharing your findings, I'm sure this will be very helpful to others stumbling upon this issue! |
What is the nginx version number you are using? |
|
Could you please test with kreait/firebase-php#903 if this solves the issue? |
Describe the bug
when sending notifications locally it works but when uploaded to the live server it gives a 411 error.
here is the error description
`cURL error 0: The cURL request was retried 3 times and did not succeed. The most likely reason for the failure is that cURL was unable to rewind the body of the request and subsequent retries resulted in the same error. Turn on the debug option to see what went wrong. See https://bugs.php.net/bug.php?id=47204 for more information. (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for https://fcm.googleapis.com/v1/projects/pixify-de9ec/messages:send
Kreait
\
Firebase
\
Exception
\
Messaging
\
MessagingError
PHP 8.3.3
11.6.0
cURL error 0: The cURL request was retried 3 times and did not succeed. The most likely reason for the failure is that cURL was unable to rewind the body of the request and subsequent retries resulted in the same error. Turn on the debug option to see what went wrong. See https://bugs.php.net/bug.php?id=47204 for more information. (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for https://fcm.googleapis.com/v1/projects/pixify-de9ec/messages:send
Expand vendor frames
20 vendor frames
Illuminate
\
Routing
\
RouteFileRegistrar
: 39
{closure}
46 vendor frames
routes
/
web
.php
: 39
// 'auth:sanctum',
// config('jetstream.auth_session'),
// 'verified',
//])->group(function () {
// Route::get('/dashboard', function () {
// return view('dashboard');
// })->name('dashboard');
//});
Route::get('/privacy_policy', function () {
})->name('privacy_policy');
Route::get('/notify', function () {
});`
Installed packages
PHP version and extensions
Steps to reproduce the issue.
Error message/Stack trace
Additional information
No response
The text was updated successfully, but these errors were encountered: