Re: [capnproto] Warnings "EventLoop destroyed with events still in the queue. Memory leak?"

2022-06-13 Thread 'Kenton Varda' via Cap'n Proto
Yes, it's normal. I agree it's kind of spammy but I haven't figured out what to do about it. On Tue, Jun 7, 2022 at 7:25 PM Jens Alfke wrote: > > > On Jun 7, 2022, at 3:07 PM, Kenton Varda wrote: > > Info-level logs are generally meant to be enabled only for debugging, so > the idea here is you

Re: [capnproto] Warnings "EventLoop destroyed with events still in the queue. Memory leak?"

2022-06-07 Thread Jens Alfke
> On Jun 7, 2022, at 3:07 PM, Kenton Varda wrote: > > Info-level logs are generally meant to be enabled only for debugging, so the > idea here is you normally shouldn't see this log. But I am debugging :) I’m debugging my code, using KJ logging. So I do see this somewhat scary-looking messag

Re: [capnproto] Warnings "EventLoop destroyed with events still in the queue. Memory leak?"

2022-06-07 Thread 'Kenton Varda' via Cap'n Proto
Hi Jens, Info-level logs are generally meant to be enabled only for debugging, so the idea here is you normally shouldn't see this log. All exceptions that are transmitted over RPC are info-logged but normally you would only want to log them in production if some actual operation you care about fa

Re: [capnproto] Warnings "EventLoop destroyed with events still in the queue. Memory leak?"

2022-06-07 Thread Jens Alfke
> On Jun 7, 2022, at 9:53 AM, 'Kenton Varda' via Cap'n Proto > wrote: > > Ideally, you should set things up so that when the stack unwinds, all Promise > objects are destroyed before the EventLoop is destroyed. Thanks! I actually figured this out shortly after posting, but forgot to send a

Re: [capnproto] Warnings "EventLoop destroyed with events still in the queue. Memory leak?"

2022-06-07 Thread 'Kenton Varda' via Cap'n Proto
Hi Jens, Sorry for the slow reply. This error indicates that the KJ EventLoop (which is part of the objects returned by kj::setupAsyncIo()) was destroyed while some kj::Promise objects still existed. Ideally, you should set things up so that when the stack unwinds, all Promise objects are destro

[capnproto] Warnings "EventLoop destroyed with events still in the queue. Memory leak?"

2022-05-23 Thread Jens Alfke
I’m in the midst of improving the error handling in my code, but there’s a warning logged by KJ that I can’t figure out. I’d appreciate any advice or insight. It happens when my client code fails to connect because server-side auth fails, so it gets an abrupt "Connection reset by peer” error th