You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There is a small memory leak which starts to show when handling lots of requests. I found a corresponding issue in the go-clamd library used: dutchcoders/go-clamd#9
Here is a small patch to fix it. I tried it and it did stabilize memory usage.
The loop to suck the chan dry seems a bit hacky to me. It would be better to address this in go-clamd itself, IMO, but if you are pressed for time, then all good.
The loop to suck the chan dry seems a bit hacky to me. It would be better to address this in go-clamd itself, IMO, but if you are pressed for time, then all good.
Agreed, it is a quickfix (I'm worried go-clamd is not maintained anymore, though I can still try a PR)
Dear @hectorj thanks for your contribution. As I wasn't able to focus on this, I've merged your fix and released v0.7.3. I anyway leave #27 open to proper fix this in go-clamd.
Cheers
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi!
First, thank you for your work on
clammit.There is a small memory leak which starts to show when handling lots of requests. I found a corresponding issue in the
go-clamdlibrary used: dutchcoders/go-clamd#9Here is a small patch to fix it. I tried it and it did stabilize memory usage.