Closed jcerdan closed 5 months ago
I'm investigating it because I've just found it's the same problem on Laravel Sail and php artisan serve
. Both start a single-threaded php process that can't handle multiple requests when notifying the fake Redsys response.
While I work on a solution for artisan serve
, you can use it with Laravel Valet or any other nginx/apache server.
Ok thanks.
With what you say I have found a workaround with php artisan serve
I have started a new server on port 8001 and add the merchantURL to the request:
$redsysRequest = RequestBuilder::newRequest(
new \Creagia\Redsys\Support\RequestParameters(
transactionType: \Creagia\Redsys\Enums\TransactionType::Autorizacion,
productDescription: 'products',
amountInCents: $cart->amount_total,
currency: Currency::EUR,
payMethods: \Creagia\Redsys\Enums\PayMethod::Card,
merchantUrl: 'http://localhost:8001/redsys/notification'
)
);
That makes the notification URL go to port 8001 and the system works fine then. (haven't yet checked that events are fired ok, but I think there should not be any problem)
Hi, I'm closing this issue because this has been fixed in the latest release. If you need this in v2, I would appreciate a PR porting this solution to the v2 branch. Thanks.
Hi,
I get this error on local environment
cURL error 28: Operation timed out after 30003 milliseconds with 0 bytes received (see https://curl.haxx.se/libcurl/c/libcurl-errors.html) for http://localhost:8000/redsys/notification
I'm not using Laravel Sail, but Laravel under php 8.2.13 on local computer.
I have set in .env the value
I'm using this to connect to local gateway (and it works fine)