Real-Time Laravel with Reverb: Example For Beginners

Поділитися
Вставка
  • Опубліковано 26 лис 2024

КОМЕНТАРІ • 55

  • @mohammadnaim9226
    @mohammadnaim9226 6 місяців тому +3

    You cover the main points in a short time and that's why your content is so good. And your tutorials are very informative. Proceed like this

  • @PhoneMyatKyaw-mi8yz
    @PhoneMyatKyaw-mi8yz 7 місяців тому +1

    I am now working on chat application and this is a lot more easy to set up for real-time application.

  • @TheCodeholic
    @TheCodeholic 7 місяців тому +7

    Concise and on point explanation! 👍

  • @Sebz9590
    @Sebz9590 7 місяців тому +1

    I was waiting for something like this for so long. Currently i have a project to handle the scores in competition, spectators see the results but every 5 seconds i have to refresh the page so spectators could see the new results. With this tool, spectators will be able to see the results in real time, it will be very practical instead of doing that refresh on the page

    • @LaravelDaily
      @LaravelDaily  7 місяців тому +1

      Very good practical example, yes!

  • @broouklynco.tutorials5606
    @broouklynco.tutorials5606 7 місяців тому +6

    So, this means that Laravel Reverb is completely free and we just should install it and work with it? Correct me if I'm wrong.

  • @AndyTalbot
    @AndyTalbot 7 місяців тому

    Been trying it out and it's great, though I did have a bit of a headache doing private channels with my SPA using sanctum.

  • @robertkwesiamoah
    @robertkwesiamoah 7 місяців тому

    Ive been able to get it working on my ubuntu server now. Nice experience.

  • @rikvandervaart2601
    @rikvandervaart2601 7 місяців тому

    Look really nice. Thanks for the vid Povilas. Just have to upgrade to 11 first in coming months to start experiementing with Reverb.

  • @aleismasanchez
    @aleismasanchez 7 місяців тому

    Good! I was waiting your videos about Reverb.

  • @skia515
    @skia515 4 місяці тому

    I install reverb and start it :
    php artisan reverb:start
    then copy and past url in browser and just get "Not found." response in browser.
    do all configures, again same response in browser.
    I mean I can not see anythingm any pages or ...

  • @ammarabdulaziz1014
    @ammarabdulaziz1014 7 місяців тому

    May I know how many web socket connections can be handled at a time? For instance, suppose we have thousands of users connected through web sockets at time, will effect the performance?

    • @LaravelDaily
      @LaravelDaily  7 місяців тому +1

      To be honest, I haven't tried with thousands, but yes it will probably addect the performance.

    • @modestasmv
      @modestasmv 7 місяців тому +1

      This server can auto-scale as written in the documentation. You might, of course, encounter challenges, but it should be fine.

  • @sandipdas4765
    @sandipdas4765 7 місяців тому

    Cpanel php artisan queue:work working but how to set when press on terminal php artisan queue:listen --tries=0 pls help when i am off. How can i run the job table when i am off. Or close the cpanel terminal

  • @philipjamesajagabos2519
    @philipjamesajagabos2519 7 місяців тому

    Any possibility of using Reverb with livewire. Instead of writing the javascript, livewire component listens for the server event and update the component ?

    • @LaravelDaily
      @LaravelDaily  7 місяців тому

      I haven't seen this implementation. You basically then need to rewrite your own Laravel Echo with Livewire.

    • @philipjamesajagabos2519
      @philipjamesajagabos2519 7 місяців тому

      @@LaravelDaily Thanks and thanks for your daily tips. 🫡

  • @KYOTF67
    @KYOTF67 7 місяців тому

    Very Nice,Sir

  • @robertkwesiamoah
    @robertkwesiamoah 7 місяців тому +2

    I've been able to use it locally... But struggling to set it up on an Ubuntu live server. Anyone with some ideas or resources to help?

    • @omaririskic98
      @omaririskic98 7 місяців тому +2

      You would have to create new supervisor worker. This worker would have a command reverb:start.
      UA-cam apparently does not allow to post links in comments, so I can't attach a specific article. Try to google Laravel supervisor and click on medium article.
      The worker code would look something like this:
      [program:laravel-reverb]
      process_name=%(program_name)s_%(process_num)02d
      command=php /path-to-your-laravel-app/artisan reverb:start
      autostart=true
      autorestart=true
      user=your-user
      numprocs=4
      redirect_stderr=true
      stdout_logfile=/var/log/laravel-reverb.log

    • @spicynoodle7419
      @spicynoodle7419 7 місяців тому +1

      Don't use the same domain/host for PUSHER in your .env file for both server and frontend.
      I think your frontend Echo instance may be trying to get events from localhost or something

    • @robertkwesiamoah
      @robertkwesiamoah 7 місяців тому

      @@spicynoodle7419 I resolved it. I used my domain as host and chose a port different ports for front and back. I created an nginx server config with SSL certificate to listen to the front and port and proxy_pass to reverb port

    • @robertkwesiamoah
      @robertkwesiamoah 7 місяців тому

      @@spicynoodle7419 I resolved it. I used my domain as host and chose a port different ports for front and back. I created an nginx server config with SSL certificate to listen to the front and port and proxy_pass to reverb port

  • @sergioriosg
    @sergioriosg 7 місяців тому

    Can I create a laravel 11 project with reverb to use it as pusher for several others laravel projects or I need to install it in every project? What is a a better option?

    • @modestasmv
      @modestasmv 7 місяців тому

      We are not sure about the "receiving" part of the application. But it should allow you to push to reverb on one instance as long as the keys are the same (and the whole configuration).
      But can you expand on this a bit more of what you want to do? Thanks!

    • @sergioriosg
      @sergioriosg 7 місяців тому

      @@modestasmv Currently, we have three different platforms created with Laravel, and all three use real-time notifications. So, my idea was to create a fourth Laravel 11 project solely to install Reverb and use it similarly to the Pusher service, where I connect my other three platforms to this fourth one with Reverb. This would allow us to reuse this project and avoid having to install Reverb on each of the other projects, which, by the way, are on Laravel 10.

    • @modestasmv
      @modestasmv 7 місяців тому

      @@sergioriosg Hmm, in theory - that should work. I'm not 100% certain tho, as you might encounter issues :)

  • @HieuNguyen-pm9uf
    @HieuNguyen-pm9uf 7 місяців тому

    So I can use this in real-time chat right, sir ? Cause now I have a problem that, the chat can't reload in the group chat you know. The first person can but the second have to refresh the page to view the chat .
    p/s: I using dispatch and events using livewire now but seem like it just doesn't work

    • @LaravelDaily
      @LaravelDaily  7 місяців тому

      I haven't seen your code so can't tell you if reverb would solve your problem. But yes you can use reverb for live chat, with Laravel Echo on the frontend with JavaScript. This is one of our examples in the course.

    • @HieuNguyen-pm9uf
      @HieuNguyen-pm9uf 7 місяців тому

      @@LaravelDaily thank you sir

  • @АртурЗарипов-б2й
    @АртурЗарипов-б2й 7 місяців тому

    Good job! Thank you!

  • @ilyasmohetna3648
    @ilyasmohetna3648 7 місяців тому

    This is amazing thank you !

  • @JouvaMoufette
    @JouvaMoufette 7 місяців тому

    How does this differ from the server side stuff for Laravel Echo?

    • @LaravelDaily
      @LaravelDaily  7 місяців тому

      What exactly do you mean by "server side stuff"?

    • @JouvaMoufette
      @JouvaMoufette 7 місяців тому +3

      @@LaravelDaily Oops, yeah I guess Echo really is just the Javascript framework part of things.
      I see now, this is just a first party socket server, as opposed to using pusher or soketi. Glad to see they have a first party solution now!

  • @mehdi_abik
    @mehdi_abik 16 днів тому

    good bro

  • @pauloclara4764
    @pauloclara4764 7 місяців тому

    Is possible to update laravel 10 to 11 in a filament project?

  • @romanboyko3909
    @romanboyko3909 7 місяців тому

    wasn't able to use Reverb as standalone websocket server, is it possible?

    • @LaravelDaily
      @LaravelDaily  7 місяців тому

      Reading on the official page: "Reverb is a first-party WebSocket server..."
      So it IS a websocket server, what do you mean?

    • @romanboyko3909
      @romanboyko3909 7 місяців тому

      ​@@LaravelDaily Right now I have project with laravel-websocket package. All other projects use it as web socket server, so I don't have to install laravel-websocket for each project. Is that possible with Reverb?

    • @romanboyko3909
      @romanboyko3909 7 місяців тому

      "Typically, Reverb provides a WebSocket server for the application in which it is installed. However, it is possible to serve more than one application using a single Reverb installation." documentation says.

    • @LaravelDaily
      @LaravelDaily  7 місяців тому +1

      Not sure, I haven't tried it this way. You need to test it out yourself.

  • @PaoloOrsato
    @PaoloOrsato 7 місяців тому

    3:26 Does Reverb work with Laravel 10?

    • @lukasneuschl
      @lukasneuschl 7 місяців тому

      Laravel Reverb requires PHP 8.2+ and Laravel 10.47+.

  • @HousseinDroubi-o9i
    @HousseinDroubi-o9i 6 місяців тому

    Hello

  • @lestratege4
    @lestratege4 2 місяці тому

    too much theory thats why i hate this channel