Skip to content
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

Memory leak? #145

Closed
vatsake opened this issue Apr 12, 2024 · 5 comments
Closed

Memory leak? #145

vatsake opened this issue Apr 12, 2024 · 5 comments

Comments

@vatsake
Copy link

vatsake commented Apr 12, 2024

Reverb Version

1.0.0-beta4

Laravel Version

11.0.8

PHP Version

8.2

Description

The memory usage keeps increasing every time events are triggered.

On a test server, I triggered ~20 events, and the memory usage increased by 200kb (and never goes back down).

Reverb memory usage on LIVE server:
11.04 21:40 120MB
12.04 08:40 218MB

I'm using Telescope as well, and yesterday Reverb ran out of memory.

INFO  Starting server on 0.0.0.0:8080 (...).  


   Symfony\Component\ErrorHandler\Error\FatalError 

  Allowed memory size of 268435456 bytes exhausted (tried to allocate 2097160 bytes)

  at vendor/laravel/telescope/src/Telescope.php:329
    325▕         }, static::$tagUsing)));
    326▕ 
    327▕         static::withoutRecording(function () use ($entry) {
    328▕             if (collect(static::$filterUsing)->every->__invoke($entry)) {
  ➜ 329▕                 static::$entriesQueue[] = $entry;
    330▕             }
    331▕ 
    332▕             if (static::$afterRecordingHook) {
    333▕                 call_user_func(static::$afterRecordingHook, new static, $entry);


   Whoops\Exception\ErrorException 

I've tried disabling Telescope, but the memory still grows. So it's not related to Telescope.

Steps To Reproduce

  1. Watch memory usage with for example htop
  2. Trigger some events
@driesvints
Copy link
Member

Hey there,

Can you first please try one of the support channels below? If you can actually identify this as a bug, feel free to open up a new issue with a link to the original one and we'll gladly help you out.

Thanks!

@vatsake
Copy link
Author

vatsake commented Apr 12, 2024

@vatsake
Copy link
Author

vatsake commented Apr 12, 2024

I've been spam-sending simple pusher:ping events with postman and the memory is still increasing gradually.

@vatsake vatsake mentioned this issue Apr 12, 2024
@martinbean
Copy link

@driesvints I think this is worthy of being re-opened given you told @vatsake to ask in places like Discord first, but they already had done so.

Also, why point people to places like Discord where there’s no input from Laravel team members? @vatsake has clearly outlined the problem and also steps to reliably reproduce the issue. This is clearly a bug, hence it bringing it to the attention of the Laravel team. This clearly isn’t a “RTFM” or “you’re using it wrong” issue, and is a bug that needs addressing either via a PR or a Laravel team member.

@driesvints
Copy link
Member

@martinbean We haven't gotten other reports of this yet. And I've already asked them to re-open an issue with a repo and specific steps so we can reproduce: #146 (comment)

"Watch memory usage with for example htop & Trigger some events" just isn't a clear way to reproduce sorry. It didn't seem like an actual bug in Reverb to me, hence why I redirected to a support channel. If we can have a repo and a clear way to reproduce then we can have another look.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants