Joseph Crawford
Joseph Crawford
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
I am not sure about pooling but it does support pipelining, we just are not using those featured. I looked into pipelining in the past which is how I know they support it
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
we have keys with ttl but we are not calling expires through ioredis. No pub/sub at the moment though that may become a reality in the future
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
but ioredis is the only communication library that we are currently using and may be where our memory issues are coming from, I have not been able to diagnose as of yet.
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
we are simply using it to query for auth purposes, storing keys which are incremented/decremented and or removed and querying for keys to see if they exist.
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
thank you, yea we are personally hitting our deno endpoints with around 400M requests a day. Every request is authenticating the request through redis queries.
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
@frigjord unfortunately I have not yet. My boss has time-boxed that task as we just threw more instances at the service in aws and for the time being it has slowed the issue but not solved it. I would love to get back to this and maybe once we are through this crunch I will be able to. If you find anything related to ioredis I would be highly interested in your findings.
40 replies
DDeno
Created by Joseph Crawford on 10/2/2024 in #help
Denols Neovim
@roeland Thanks for that suggestion, I have added it but I still get the same error after restarting neovim.
3 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
yea I am just a bit concerned with enabling the debugger on production but will speak to my boss about it. I am also going to see if there is a way I could write a script possibly on a lower environment to simulate a ton of traffic to the service and maybe run the debugger there and see if I can replicate the issue.
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
the issue I see is that it is not all containers recycling, it is one container but it seems to happen several times a day
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
we do have 5 containers running but we are sending between 200-300M messages per day so it is high load.
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
Pusher: 5.2.0, Winston 3.8.2 and deno/std@0.224.0
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
I have not found there to be any memory issues reported in these versions, also these are updated versions as we were using older versions and thought that may be the source of the issue.
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
We are using Oak 16.1.0, Zod 3.23.8 and ioredis 5.3.2
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
the clients can also send a pusher message through our api which will just add the message to a redis queue, another container which runs the queue consumer will process these messages and send them out through pusher for clients to receive. The consumer being a seperate service does not seem to suffer from this memory issue at all.
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
Sure, we are using Deno 1.46.3 in production, the app is quite simple it is running an api server which uses Oak for the routing. The application will check redis with every request to authenticate the bearer token and then will simply either add a channel (or increment the value) for a channel name, it will also on another endpoint remove or decrement the value of a key. during the subscription process it will authroize with the pusher js library and return the value of that from the server to the pusher client library.
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
yea I thought about this as well, however, if the container is crashing it would cause me to believe that the memory is needed but has not been released. I am pretty sure the containers are crashing since they are being taken down by auto scaling, if they were not then it would simply spin up another instance wait until it leveled out and take down the extra instance. What we are seeing everytime is that memory hits the peak, then a new conainer is brought up and then the one that was high in memory usage is taken down. I am not sure how to check chrome dev tools since that would entail having to have debugging enabled and this seems to only happen in production under heavy load. It is not happening in our sandbox or staging environments.
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
Anyone have any ideas on tools that can be used with Deno? I will assume no if no one replies.
40 replies
DDeno
Created by Joseph Crawford on 9/12/2024 in #help
Deno Memory Usage Increases, Does Not Decrease.
Yea I was thinking the same thing, this is why I came to ask if there were any tools for Deno that may shed some light on where this may be coming from. We are using Oak so I assumed that when the controllers were completed the GC would clean up this stuff but looking through the code I do not see any blatant areas in which a memory leak would be caused. The controllers are quite simple the subscribe endpoint will reach out to an api to get some data, determine if the user can subscribe to a channel and then adds a channel to redis. The unsubscribe endpoint will reach out to redis and remove a channel, the authorize channel simply reaches out to pusher to authorize the subscription. It would be nice if there was a tool that I am unaware of that may allow me to trace the executions to a file for inspection to determine where this leak may be coming from.
40 replies