Several issues found with the extension while going over errors from our hosted communities:

  • Queue jobs would hit the timeout because the default timeout is 60s, which has now been increased. Sending took a long time because it loops over all recipients then dispatches the websocket event synchronously, with the:
  • upgrade of the pusher php library events are now dispatched asynchronously
  • events send to guest users would never arrived, realtime switched from channel public to guests a while ago
  • duplicate events would be sent for events for non public discussions and the likes
    3 months later

    A while ago I removed all plans from this extension as configuring it seems to be very problematic. Now that our Blomstra hosting platform has been released, I want to move forward in making this extension stable. For this I need a couple of patient people willing to install, configure and run the extension. We'll do this so that we can improve the documentation and ready the extension up for wider use.

    If you have an interest in helping out, please contact me on discord, I will grant you a free lifetime license of this extension in return for active bug reporting, testing and patience.

    Edit: I have sufficient testers, thanks for your interest everyone. Will ship a new version soon.

    15 days later

    Will it be possible to configure this under a path (e.g. /scoket) on hosts that do not allow open ports and the only ports available are 80 and 443?

      rafaucau You can just use a reverse proxy to do this job.

      I'm personally using this configuration:

              location ^~ /app/REPLACE_APP_KEY_HERE {
                      proxy_pass http://127.0.0.1:6001;
                      proxy_http_version 1.1;
                      proxy_set_header Upgrade $http_upgrade;
                      proxy_set_header Connection "Upgrade";
                      proxy_set_header Host $host;
              }

        pkernstock I have hosting where their administrators manage the server. The client doesn't have access to advanced features there (so as not to break something).
        The site is on a Litespeed server, so I can use .htaccess, but I don't think I can do a reverse proxy there.


        Thanks for the reverse proxy idea. I will ask the hosting support if they would do that.
        When I asked about opening ports, they said that for security reasons they can't do it.

          10 months later

          Blomstra Realtime is now available for everyone to subscribe to. This websocket extension that powers the experience of realtime on Discuss has been created to offer a self-hosted alternative to the Flarum Pusher extension. It's extremely scalable, tested with thousands of concurrent users 💪

          Starting development last year and writing everything from scratch, including the actual operation of a websocket server, we are overly excited to bring this extension to the ecosystem. Due to the complexity of this extension and the hours invested to make this scalable, bug free and performant while promising to do this moving forward, we cannot provide it for free, but I hope we made it interesting for everyone regardless.

          There are two plans, read the OP for all the details, but in a nutshell:

          • A not-for-profit plan where you take care of installation and configuration at a very low, one-off lifetime cost.
          • A for-profit plan with support, including hands-on for installation, at a recurring subscription.

          The plans are available through links in the OP only, because I want to prevent people from subscribing to the not-for-profit license without understanding what they signed up for 😉

          If you have any questions, let me know.
          If you are already using realtime, share the love 🙂

            6 days later

            luceos Can you make a setup document for the LEMP server? I still can't get it to work 🙂

            This is how I configured it.
            Fixed the delayed notification issue in the notification bell with 1.5, right?

              mekici Can you test what happens if instead of location @ws { you use location /app {?

              5 days later

              I seem to be having some issues installing this.
              What I'm doing:

              docker container run --rm -it webdevops/php-nginx:8.1 bash
              cd /app
              composer create-project flarum/flarum .
              composer config repositories.extiverse composer https://extiverse.com/composer/
              composer config --global --auth bearer.extiverse.com AAAAAA....mytoken
              composer require -W blomstra/realtime:"*"

              I then get this error:

              Your requirements could not be resolved to an installable set of packages.
              
                Problem 1
                  - blomstra/realtime 0.2 requires pusher/pusher-php-server ^4.1.5 -> found pusher/pusher-php-server[v4.1.5] but these were not loaded, likely because it conflicts with another require.
                  - blomstra/realtime[0.2.1, ..., 0.2.9] require pusher/pusher-php-server ^7.0.1 -> found pusher/pusher-php-server[7.0.1, 7.0.2] but these were not loaded, likely because it conflicts with another require.
                  - Root composer.json requires blomstra/realtime * -> satisfiable by blomstra/realtime[0.2, ..., 0.2.9].
              
              
              Installation failed, reverting ./composer.json and ./composer.lock to their original content.

              composer self-update
              You are already using the latest available Composer version 2.4.2 (stable channel).

                Kulga Uninstall pusher with the core extension. Then try again.
                composer remove flarum/pusher

                Released 0.2.10:

                • fix: activity is pushed into users page discussions
                • add nginx include file for simpler use
                • updated readme with configuration options and nginx include file

                It should now be much easier to configure Realtime with Nginx. You don't need any Upgrade parameters outside of your server block, just add the include or copy/paste it into the existing server block 👍

                Kulga as the others mentioned, remove flarum/pusher and kyrne/websocket. Let us know whether that solves it for you.

                Yup, that resolved it

                luceos If you are already using realtime, share the love 🙂

                I've been using realtime for a forum about an open-source project since the early beta days, which should be about a year by now. I'm really much enjoying the real-time experience (pun intended) the extension adds to the community forum, and obviously also the support and efforts @luceos has been providing during the setup-phase. Since then, the extension does a great job without any issues.

                Just one thing what I've been forgetting in early days: Restarting the realtime service on the server after an update of Flarum or the extension.

                  22 days later

                  Release version 0.2.11, which upgrades the pusher dependencies to 7.2.0 for PHP and 7.4.0 for JS. Make sure to install 0.2.11 if you have updated with composer recently as it would automatically pull in these pusher dependencies.

                  16 days later

                  pkernstock Restarting the realtime service on the server after an update of Flarum or the extension.

                  I know that with Redis queues, the command would be php flarum queue:restart. For Blomstra/Realtime, is there a specific command to restart the service likephp flarum realtime:restart?

                  Thanks! 👍

                    Lurker sadly nothing like that exists, but it would be interesting to add.. You can restart the service after an update manually or give sudoers access to your user to restart the service without a password in ci/cd encironments.

                    10 days later

                    luceos Queue jobs would hit the timeout because the default timeout is 60s

                    Is this still the case for the most recent version of Realtime? I know that the default is set to 120s, but what would you say is the safe threshold for the interval? Thanks!